Part Number Hot Search : 
CD295090 TDA46052 37509 25ETT MT336230 10405 A29FAG SM77H
Product Description
Full Text Search
 

To Download ADUC824B2 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  rev. 0 a aduc834 microconverter , dual 16-bit/24-bit - adcs with embedded 62 kb flash mcu information furnished by analog devices is believed to be accurate and reliable. however, no responsibility is assumed by analog devices for its use, nor for any infringements of patents or other rights of third parties that may result from its use. no license is granted by implication or otherwise under any patent or patent rights of analog devices. trademarks and registered trademarks are the property of their respective companies. one technology way, p.o. box 9106, norwood, ma 02062-9106, u.s.a. tel: 781/329-4700 www.analog.com fax: 781/326-8703 ?2002 analog devices, inc. all rights reserved. functional block diagram 62 kbytes flash/ee program memory 4 kbytes flash/ee data memory 2304 bytes user ram 3 16 bit timers baud r ate timer 4 parallel ports 8051-based mcu with additional peripherals power supply mon watchdog timer uart, spi, and i 2 c serial i/o aduc834 xtal2 xtal1 buf agnd refin+ refin internal band gap v ref ain1 ain2 ain3 ain4 ain5 auxiliary 16-bit - adc primary 24-bit - adc mux osc av dd mux pga dual 16-bit - dac buf dac current source av dd iexc1 iexc2 pwm0 pwm1 dual 16-bit pwm w ake- up/ rtc timer temp sensor external v ref detect 12-bit dac mux dgnd dv dd reset por pll and prog clock div general description the aduc834 is a complete smart transducer front end, inte grating two high resolution  -  adcs, an 8-bit mcu, and program/data flash/ee memory on a single chip. the two independent adcs (primary and auxiliary) include a temperature sensor and a pga (allowing direct measurement of low level signals). the adcs with on-chip digital filtering and programmable output data rates are intended for the measurement of wide dynamic range, low frequency signals, such as those in weigh scale, strain-gage, pressure transducer, or temperature measurement applications. the device operates from a 32 khz crystal with an on-chip pll generating a high frequency clock of 12.58 mhz. this clock is routed through a programmable clock divider from which the mcu core clock operating frequency is generated. the microcontroller core is an 8052 and therefore 8051 instruction set compatible with 12 core clock periods per machine cycle. 62 kbytes of nonvolatile flash/ee program memory, 4 kbytes of nonvolatile flash/ee data memory, and 2304 bytes of data ram are provided on-chip. the program memory can be configured as data memory to give up to 60 kbytes of nv data memory in data logging applications. on-chip factory firmware supports in-circuit serial download and debug modes (via uart), as well as single-pin emulation mode via the ea pin. the aduc834 is supported by a quickstart development system featuring low cost software and hardware development tools. features high resolution - adcs 2 independent adcs (16-bit and 24-bit resolution) 24-bit no missing codes, primary adc 21-bit rms (18.5-bit p-p) effective resolution @ 20 hz offset drift 10 nv/ c, gain drift 0.5 ppm/ c memory 62 kbytes on-chip flash/ee program memory 4 kbytes on-chip flash/ee data memory flash/ee, 100 year retention, 100 kcycles endurance 3 levels of flash/ee program memory security in-circuit serial download (no external hardware) high speed user download (5 seconds) 2304 bytes on-chip data ram 8051-based core 8051 compatible instruction set 32 khz external crystal on-chip programmable pll (12.58 mhz max) 3 16-bit timer/counter 26 programmable i/o lines 11 interrupt sources, two priority levels dual data pointer, extended 11-bit stack pointer on-chip peripherals internal power on reset circuit 12-bit voltage output dac dual 16-bit - dacs/pwms on-chip temperature sensor dual excitation current sources time interval counter (wake-up/rtc timer) uart, spi , and i 2 c serial i/o high speed baud rate generator (including 115,200) watchdog timer (wdt) power supply monitor (psm) power normal: 2.3 ma max @ 3.6 v (core clk = 1.57 mhz) power-down: 20 a max with wake-up timer running specified for 3 v and 5 v operation package and temperature range 52-lead mqfp (14 mm 14 mm), ?0 c to +125 c 56-lead lfcsp (8 mm 8 mm), ?0 c to +85 c applications intelligent sensors weigh scales portable instrumentation, battery-powered systems 4?0 ma transmitters data logging precision system monitoring
rev. 0 ? aduc834 table of contents features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 functional block diagram . . . . . . . . . . . . . . . . . 1 general description . . . . . . . . . . . . . . . . . . . . . . . 1 specifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 absolute maximum ratings . . . . . . . . . . . . . . . . 9 ordering guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 pin configurations . . . . . . . . . . . . . . . . . . . . . . . . . 9 detailed block diagram . . . . . . . . . . . . . . . . . . 10 pin function descriptions . . . . . . . . . . . . . . . . 10 memory organization . . . . . . . . . . . . . . . . . . . . . 13 special function registers (sfrs) . . . . . . . . 14 accumulator (acc) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 b sfr (b) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 data pointer (dptr) . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 stack pointer (sp and sph) . . . . . . . . . . . . . . . . . . . . . . 15 program status word (psw) . . . . . . . . . . . . . . . . . . . . . . 15 power control sfr (pcon) . . . . . . . . . . . . . . . . . . . . . . 15 aduc834 configuration sfr (cfg834) . . . . . . . . . . . . 15 complete sfr map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 adc sfr interface adcstat . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 adcmode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 adc0con . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 adc1con . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 adc0h/adc0m/adc0l/adc1h/adc1l . . . . . . . . . . 20 of0h/of0m/of0l/of1h/of1l . . . . . . . . . . . . . . . . . 20 gn0h/gn0m/gn0l/gn1h/gn1l . . . . . . . . . . . . . . . . 20 sf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 icon . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 primary and auxiliary adc noise performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 primary and auxiliary adc circuit description overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 primary adc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 auxiliary adc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 analog input channels . . . . . . . . . . . . . . . . . . . . . . . . . . 24 primary and auxiliary adc inputs . . . . . . . . . . . . . . . . . 25 analog input ranges . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25 programmable gain amplifier . . . . . . . . . . . . . . . . . . . . . 25 bipolar/unipolar inputs . . . . . . . . . . . . . . . . . . . . . . . . . . 25 reference input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 burnout currents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 excitation currents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 reference detect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26  -  modulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 digital filter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 adc chopping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 calibration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 nonvolatile flash/ee memory flash/ee memory overview . . . . . . . . . . . . . . . . . . . . . . 28 flash/ee memory and the aduc834 . . . . . . . . . . . . . . . 28 aduc834 flash/ee memory reliability . . . . . . . . . . . . . 29 flash/ee program memory . . . . . . . . . . . . . . . . . . . . . . . 30 serial downloading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 parallel programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 user download mode (uload) . . . . . . . . . . . . . . . . . . 30 flash/ee program memory security . . . . . . . . . . . . . . . . 31 lock, secure, and serial safe modes . . . . . . . . . . . . . . . . 31 using the flash/ee data memory . . . . . . . . . . . . . . . . . . 31 econ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 programming the flash/ee data memory . . . . . . . . . . . . 33 flash/ee memory timing . . . . . . . . . . . . . . . . . . . . . . . . 33 other on-chip peripherals dac . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 pulsewidth modulator (pwm) . . . . . . . . . . . . . . . . . . . . . 36 on-chip pll . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 time interval counter (wake-up/rtc timer) . . . . . . . . 40 watchdog timer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42 power supply monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 serial peripheral interface (spi) . . . . . . . . . . . . . . . . . . . . 44 i 2 c serial interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46 dual data pointer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 8052 compatible on-chip peripherals parallel i/o ports 0? . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 timers/counters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 uart serial interface . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 uart operating modes . . . . . . . . . . . . . . . . . . . . . . . . . 57 baud rate generation using timer 1 and timer 2 . . . . . 59 baud rate generation using timer 3 . . . . . . . . . . . . . . . 60 interrupt system . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 hardware design considerations external memory interface . . . . . . . . . . . . . . . . . . . . . . . 63 power supplies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 power-on reset (por) operation . . . . . . . . . . . . . . . . . . 64 power consumption . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 power saving modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65 wake-up from power-down latency . . . . . . . . . . . . . . . 65 grounding and board layout recommendations . . . . . . 65 aduc834 system self-identification . . . . . . . . . . . . . . . . 66 clock oscillator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 other hardware considerations in-circuit serial download access . . . . . . . . . . . . . . . . . 67 embedded serial port debugger . . . . . . . . . . . . . . . . . . . 67 single-pin emulation mode . . . . . . . . . . . . . . . . . . . . . . . 67 typical system configuration . . . . . . . . . . . . . . . . . . . . . 68 quickstart development system . . . . . . . . . 69 timing specifications . . . . . . . . . . . . . . . . . . . . . . 70 outline dimensions . . . . . . . . . . . . . . . . . . . . . . . . 80
rev. 0 aduc834 ? parameter aduc834 test conditions/comments unit adc specifications conversion rate 5.4 on both channels hz min 105 programmable in 0.732 ms increments hz max primary adc no missing codes 2 24 20 hz update rate bits min resolution 13.5 range = 20 mv, 20 hz update rate bits p-p typ 18.5 range = 2.56 v, 20 hz update rate bits p-p typ output noise see tables x and xi output noise varies with selected in aduc834 adc update rate and gain range description integral nonlinearity 15 1 lsb 16 ppm of fsr max offset error 3 3 v typ offset error drift 10 nv/ c typ full-scale error 4 10 v typ gain error drift 5 0.5 ppm/ c typ adc range matching 2ain = 18 mv v typ power supply rejection (psr) 113 ain = 7.8 mv, range = 20 mv dbs typ 80 ain = 1 v, range = 2.56 v dbs min common-mode dc rejection on ain 95 at dc, ain = 7.8 mv, range = 20 mv dbs min 113 at dc, ain = 1 v, range = 2.56 v dbs typ on refin 125 at dc, ain = 1 v, range = 2.56 v dbs typ common-mode 50 hz/60 hz rejection 2 20 hz update rate on ain 95 50 hz/60 hz 1h z, ain = 7.8 mv, dbs min range = 20 mv 90 50 hz/60 hz 1h z, ain = 1 v, dbs min range = 2.56 v on refin 90 50 hz/60 hz 1h z, ain = 1 v, dbs min range = 2.56 v normal mode 50 hz/60 hz rejection 2 on ain 60 50 hz/60 hz 1h z, 20 hz update rate dbs min on refin 60 50 hz/60 hz 1h z, 20 hz update rate dbs min auxiliary adc no missing codes 2 16 bits min resolution 16 range = 2.5 v, 20 hz update rate bits p-p typ output noise see table xii in output noise varies with selected aduc834 adc update rate description integral nonlinearity 15 ppm of fsr max offset error 3 ? lsb typ offset error drift 1 v/ c typ full-scale error 6 ?.5 lsb typ gain error drift 5 0.5 ppm/ c typ power supply rejection (psr) 80 ain = 1 v, 20 hz update rate dbs min normal mode 50 hz/60 hz rejection 2 on ain 60 50 hz/60 hz 1hz dbs min on refin 6 05 0 hz/60 hz 1 hz, 20 hz update rate dbs min dac performance dc specifications 7 resolution 12 bits relative accuracy 3lsb typ differential nonlinearity ? guaranteed 12-bit monotonic lsb max offset error 50 mv max gain error 8 1av dd range % max 1v ref range % typ ac specifications 2, 7 voltage output settling time 15 settling time to 1 lsb of final value s typ digital-to-analog glitch energy 10 1 lsb change at major carry nvs typ specifications 1 (av dd = 2.7 v to 3.6 v or 4.75 v to 5.25 v, dv dd = 2.7 v to 3.6 v or 4.75 v to 5.25 v, refin(+) = 2.5 v, refin(? = agnd; agnd = dgnd = 0 v; xtal1/xtal2 = 32.768 khz crystal; all specifications t min , to t max unless otherwise noted.)
rev. 0 ? aduc834 parameter aduc834 test conditions/comments unit internal reference adc reference reference voltage 1.25 1% initial tolerance @ 25 c, v dd = 5 v v min/max power supply rejection 45 dbs typ reference tempco 100 ppm/ c typ dac reference reference voltage 2.5 1% initial tolerance @ 25 c, v dd = 5 v v min/max power supply rejection 50 dbs typ reference tempco 100 ppm/ c typ analog inputs/reference inputs primary adc differential input voltage ranges 9, 10 external reference voltage = 2.5 v rn2, rn1, rn0 of adc0con set to bipolar mode (adc0con3 = 0) 20 0 0 0 (unipolar mode 0 mv to 20 mv) mv 40 0 0 1 (unipolar mode 0 mv to 40 mv) mv 80 0 1 0 (unipolar mode 0 mv to 80 mv) mv 160 0 1 1 (unipolar mode 0 mv to 160 mv) mv 320 1 0 0 (unipolar mode 0 mv to 320 mv) mv 640 1 0 1 (unipolar mode 0 mv to 640 mv) mv 1.28 1 1 0 (unipolar mode 0 v to 1.28 v) v 2.56 1 1 1 (unipolar mode 0 v to 2.56 v) v analog input current 2 1t max = 85 cna max 5t max = 125 cna max analog input current drift 5t max = 85 cpa/ c typ 15 t max = 125 cpa/ c typ absolute ain voltage limits 2 agnd + 100 mv v min av dd ?100 mv v max auxiliary adc input voltage range 9, 10 0 to v ref unipolar mode, for bipolar mode v see note 11 average analog input current 125 input current will vary with input na/v typ average analog input current drift 2 2 voltage on the unbuffered auxiliary adc pa/v/ c typ absolute ain voltage limits 2, 11 agnd ?30 mv v min av dd + 30 mv v max external reference inputs refin(+) to refin(? range 2 1v min av dd v max average reference input current 1 both adcs enabled a/v typ average reference input current drift 0.1 na/v/ c typ ?o ext. ref?trigger voltage 0.3 noxref bit active if v ref < 0.3 v v min 0.65 noxref bit inactive if v ref > 0.65 v v max adc system calibration full-scale calibration limit +1.05 fs v max zero-scale calibration limit ?.05 fs v min input span 0.8 fs v min 2.1 fs v max analog (dac) output voltage range 0 to v ref dacrn = 0 in daccon sfr v typ 0 to av dd dacrn = 1 in daccon sfr v typ resistive load 10 from dac output to agnd k w typ capacitive load 100 from dac output to agnd pf typ output impedance 0.5 w typ i sink 50 a typ temperature sensor accuracy 2 c typ thermal impedance ( ja )9 0 mqfp package c/w typ 52 csp package (base floating) 12 c/w typ specifications (continued)
rev. 0 aduc834 ? parameter aduc834 test conditions/comments unit transducer burnout current sources ain+ current ?00 ain+ is the selected positive input to na typ the primary adc ain?current +100 ain?is the selected negative input to na typ the auxiliary adc initial tolerance @ 25 c 10 % typ drift 0.03 %/ c typ excitation current sources output current ?00 available from each current source a typ initial tolerance @ 25 c 10 % typ drift 200 ppm/ c typ initial current matching @ 25 c 1 matching between both current sources % typ drift matching 20 ppm/ c typ line regulation (av dd )1 av dd = 5 v + 5% a/v typ load regulation 0.1 a/v typ output compliance 2 av dd ?0.6 v max agnd min logic inputs all inputs except sclock, reset, and xtal1 2 v inl , input low voltage 0.8 dv dd = 5 v v max 0.4 dv dd = 3 v v max v inh , input high voltage 2.0 v min sclock and reset only (schmitt-triggered inputs) 2 v t+ 1.3/3 dv dd = 5 v v min/v max 0.95/2.5 dv dd = 3 v v min/v max v t 0.8/1.4 dv dd = 5 v v min/v max 0.4/1.1 dv dd = 3 v v min/v max v t+ ?v t 0.3/0.85 dv dd = 5 v v min/v max 0.3/0.85 dv dd = 3 v v min/v max input currents port 0, p1.2?1.7, ea 10 v in = 0 v or v dd a max sclock, mosi, miso, ss 13 ?0 min, ?0 max v in = 0 v, dv dd = 5 v, internal pull-up a min/ a max 10 v in = v dd , dv dd = 5 v a max reset 10 v in = 0 v, dv dd = 5 v a max 35 min, 105 max v in = v dd , dv dd = 5 v, internal pull-down a min/ a max p1.0, p1.1, ports 2 and 3 10 v in = v dd , dv dd = 5 v a max ?80 v in = 2 v, dv dd = 5 v a min ?60 a max ?0 v in = 450 mv, dv dd = 5 v a min ?5 a max input capacitance 5 all digital inputs pf typ crystal oscillator (xtal1 and xtal2) logic inputs, xtal1 only 2 v inl , input low voltage 0.8 dv dd = 5 v v max 0.4 dv dd = 3 v v max v inh , input high voltage 3.5 dv dd = 5 v v min 2.5 dv dd = 3 v v min xtal1 input capacitance 18 pf typ xtal2 output capacitance 18 pf typ
rev. 0 ? aduc834 specifications (continued) parameter aduc834 test conditions/comments unit logic outputs (not including xtal2) 2 v oh , output high voltage 2.4 v dd = 5 v, i source = 80 av min 2.4 v dd = 3 v, i source = 20 av min v ol , output low voltage 14 0.4 i sink = 8 ma, sclock, v max mosi/sdata 0.4 i sink = 10 ma, p1.0 and p1.1 v max 0.4 i sink = 1.6 ma, all other outputs v max floating state leakage current 2 10 a max floating state output capacitance 5 pf typ power supply monitor (psm) av dd trip point selection range 2. 63 four trip points selectable in this range v min 4.63 programmed via tpa1? in psmcon v max av dd power supply trip point accuracy 3.0 t max = 85 c% max 4.0 t max = 125 c% max dv dd trip point selection range 2. 63 four trip points selectable in this range v min 4.63 programmed via tpd1? in psmcon v max dv dd power supply trip point accuracy 3.0 t max = 85 c% max 4.0 t max = 125 c% max watchdog timer (wdt) timeout period 0 nine timeout periods in this range ms min 2000 programmed via pre3? in wdcon ms max mcu core clock rate clock rate generated via on-chip pll mcu clock rate 2 98.3 programmable via cd2? bits in khz min pllcon sfr 12.58 mhz max start-up time at power-on 300 ms typ after external reset in normal mode 3 ms typ after wdt reset in normal mode 3 controlled via wdcon sfr ms typ from idle mode 10 s typ from power-down mode oscillator running osc_pd bit = 0 in pllcon sfr wake-up with int0 interrupt 20 s typ wake-up with spi interrupt 20 s typ wake-up with tic interrupt 20 s typ wake-up with external reset 3 ms typ oscillator powered down osc_pd bit = 1 in pllcon sfr wake-up with int0 interrupt 20 s typ wake-up with spi interrupt 20 s typ wake-up with external reset 5 ms typ flash/ee memory reliability characteristics 15 endurance 16 100,000 cycles min data retention 17 100 years min
rev. 0 aduc834 ? parameter aduc834 test conditions/comments unit power requirements dv dd and av dd can be set independently power supply voltages av dd , 3 v nominal operation 2.7 v min 3.6 v max av dd , 5 v nominal operation 4.75 v min 5.25 v max dv dd , 3 v nominal operation 2.7 v min 3.6 v max dv dd , 5 v nominal operation 4.75 v min 5.25 v max 5 v power consumption dv dd = 4.75 v to 5.25 v, av dd = 5.25 v power supply currents normal mode 18, 19 dv dd current 4 core clk = 1.57 mhz ma max dv dd current 13 core clk = 12.58 mhz ma typ 16 core clk = 12.58 mhz ma max av dd current 180 core clk = 1.57 mhz or 12.58 mhz a max typical additional power supply currents core clk = 1.57 mhz (ai dd and di dd ) psm peripheral 50 a typ primary adc 1 ma typ auxiliary adc 500 a typ dac 150 a typ dual current sources 400 a typ 3 v power consumption dv dd = 2.7 v to 3.6 v power supply currents normal mode 18, 19 dv dd current 2.3 core clk = 1.57 mhz ma max dv dd current 8 core clk = 12.58 mhz ma typ 10 core clk = 12.58 mhz ma max av dd current 180 av dd = 5.25 v, core clk = 1.57 mhz or 12.58 mhz a max p ower supply currents power-down mode 18, 19 core clk = 1.57 mhz or 12.58 mhz dv dd current 20 t max = 85 c; osc. on, tic on a max 40 t max = 125 c; osc. on, tic on a max dv dd current 10 osc. off a typ av dd current 1 av dd = 5.25 v; t max = 85 c; osc. on or osc. off a max 3av dd = 5.25 v; t max = 125 c; osc. on or osc. off a max
rev. 0 ? aduc834 notes 1 temperature range for aduc834bs (mqfp package) is ?0 c to +125 c. temperature range for aduc834bcp (csp package) is ?0 c to +85 c. 2 these numbers are not production tested but are guaranteed by design and/or characterization data on production release. 3 system zero-scale calibration can remove this error. 4 the primary adc is factory calibrated at 25 c with av dd = dv dd = 5 v yielding this full-scale error of 10 v. if user power supply or temperature conditions are significantly different from these, an internal full-scale calibration will restore this error to 10 v. a system zero-scale and full-scale calibration will remove this error altogether. 5 gain error drift is a span drift. to calculate full-scale error drift, add the offset error drift to the gain error drift times the full-scale input. 6 the auxiliary adc is factory calibrated at 25 c with av dd = dv dd = 5 v yielding this full-scale error of ?.5 lsb. a system zero-scale and full-scale calibration will remove this error altogether. 7 dac linearity and ac specifications are calculated using: reduced code range of 48 to 4095, 0 to v ref ; reduced code range of 100 to 3950, 0 to v dd . 8 gain error is a measure of the span error of the dac. 9 in general terms, the bipolar input voltage range to the primary adc is given by rangeadc = (v ref 2 rn )/125, where: v ref = refin(+) to refin(? voltage and v ref = 1.25 v when internal adc v ref is selected. rn = decimal equivalent of rn2, rn1, rn0, e.g., v ref = 2.5 v and rn2, rn1, rn0 = 1, 1, 0 the range adc = 1.28 v. in unipolar mode, the effective range is 0 v to 1.28 v in our example. 10 1.25 v is used as the reference voltage to the adc when internal v ref is selected via xref0 and xref1 bits in adc0con and adc1con, respectively. 11 in bipolar mode, the auxiliary adc can only be driven to a minimum of agnd ?30 mv as indicated by the auxiliary adc absolute a in voltage limits. the bipolar range is still ? ref to +v ref ; however, the negative voltage is limited to ?0 mv. 12 the aduc834bcp (csp package) has been qualified and tested with the base of the csp package floating. 13 pins configured in spi mode, pins configured as digital inputs during this test. 14 pins configured in i 2 c mode only. 15 flash/ee memory reliability characteristics apply to both the flash/ee program memory and flash/ee data memory. 16 endurance is qualified to 100 kcycles as per jedec std. 22 method a117 and measured at ?0 c, +25 c, +85 c, and +125 c. typical endurance at 25 c is 700 kcycles. 17 retention lifetime equivalent at junction temperature (t j ) = 55 c as per jedec std. 22, method a117. retention lifetime based on an activation energy of 0.6ev will derate with junction temperature as shown in figure 16 in the flash/ee memory section of this data sheet. 18 power supply current consumption is measured in normal, idle, and power-down modes under the following conditions: normal mode: reset = 0.4 v, digital i/o pins = open circuit, core clk changed via cd bits in pllcon, core executing internal so ftware loop. idle mode: reset = 0.4 v, digital i/o pins = open circuit, core clk changed via cd bits in pllcon, pcon.0 = 1, core execution s uspended in idle mode. power-down mode: reset = 0.4 v, all p0 pins and p1.2?1.7 pins = 0.4 v, all other digital i/o pins are open circuit, core clk c hanged via cd bits in pllcon, pcon.1 = 1, core execution suspended in power-down mode, osc turned on or off via osc_pd bit (pllcon.7) in pllcon sfr. 19 dv dd power supply current will increase typically by 3 ma (3 v operation) and 10 ma (5 v operation) during a flash/ee memory progra m or erase cycle. specifications subject to change without notice.
rev. 0 aduc834 ? caution esd (electrostatic discharge) sensitive device. electrostatic charges as high as 4000 v readily accumulate on the human body and test equipment and can discharge without detection. although the aduc834 features proprietary esd protection circuitry, permanent damage may occur on devices subjected to high energy electrostatic discharges. therefore, proper esd precautions are recommended to avoid performance degradation or loss of functionality. absolute maximum ratings 1 (t a = 25 c, unless otherwise noted.) av dd to agnd . . . . . . . . . . . . . . . . . . . . . . . ?.3 v to +7 v av dd to dgnd . . . . . . . . . . . . . . . . . . . . . . . ?.3 v to +7 v dv dd to agnd . . . . . . . . . . . . . . . . . . . . . . . ?.3 v to +7 v dv dd to dgnd . . . . . . . . . . . . . . . . . . . . . . . ?.3 v to +7 v agnd to dgnd 2 . . . . . . . . . . . . . . . . . . . . ?.3 v to +0.3 v av dd to dv dd . . . . . . . . . . . . . . . . . . . . . . . . . . 2 v to +5 v analog input voltage to agnd 3 . . . . ?.3 v to av dd + 0.3 v reference input voltage to agnd . . ?.3 v to av dd + 0.3 v ain/refin current (indefinite) . . . . . . . . . . . . . . . . . 30 ma digital input voltage to dgnd . . . . ?.3 v to dv dd + 0.3 v digital output voltage to dgnd . . . ?.3 v to dv dd + 0.3 v operating temperature range . . . . . . . . . . ?0 c to +125 c storage temperature range . . . . . . . . . . . . ?5 c to +150 c junction temperature . . . . . . . . . . . . . . . . . . . . . . . . . . 150 c  ja thermal impedance (mqfp) . . . . . . . . . . . . . . . . 90 c/w  ja thermal impedance (lfcsp base floating) . . . . . 52 c/w lead temperature, soldering vapor phase (60 sec) . . . . . . . . . . . . . . . . . . . . . . . . . 215 c infrared (15 sec) . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220 c notes 1 stresses above those listed under absolute maximum ratings may cause perma- nent damage to the device. this is a stress rating only; functional operation of the device at these or any other conditions above those listed in the operational sections of this specification is not implied. exposure to absolute maximum rating condi- tions for extended periods may affect device reliability. 2 agnd and dgnd are shorted internally on the aduc834. 3 applies to p1.2 to p1.7 pins operating in analog or digital input modes. pin configuration 52-lead mqfp 1 13 14 26 40 52 27 39 aduc834 top view (not to scale) pin 1 identifier 56-lead lfcsp pin 1 identifier 1 14 15 28 29 42 43 56 aduc834 top view (not to scale) ordering guide temperature package package model range description option aduc834bs ?0 c to +125 c 52-lead plastic quad flatpack s-52 aduc834bcp ?0 c to +85 c 56-lead frame chip scale package cp-56 eval-aduc834qs quickstart development system
rev. 0 ?0 aduc834 pll with prog. clock divider watchdog timer 2304 bytes user ram power supply monitor ain3 ain4 ain5 ain1 ain2 refin refin iexc 2 iexc 1 ain mux temp sensor ain mux band gap reference v ref detect current source mux 200 a 200 a 5 av dd 6 agnd 20 21 dgnd 35 26 sclock 27 mosi/sdata 14 miso 13 ss xtal1 p0.0 (ad0) p0.1 (ad1) p0.3 (ad3) p0.4 (ad4) p0.5 (ad5) p0.6 (ad6) p0.7 (ad7) 43 44 45 46 49 50 51 52 p0.2 (ad2) buf aduc834 auxiliary adc 16-bit - adc adc control and calibration pga primary adc 24-bit - adc adc control and calibration 3 22 t0 23 t1 2 t2ex t2 1 18 int0 19 int1 dac 40 ea 41 psen 17 txd 16 rxd 4 kbytes data flash/ee 62 kbytes program/ flash/ee uart serial port 8052 mcu core downloader debugger buf single-pin emulator spi/i 2 c serial interface 16-bit counter timers wake-up/ rtc timer xtal2 33 osc p1.0 (t2) p1.1 (t2ex) p1.2 (dac/iexc 1) p1.4 (ain1) p1.5 (ain2) p1.6 (ain3) p1.7 (ain4/dac) p1.3 (ain5/iexc 2) 1 2 3 4 9 10 11 12 p2.0 (a8/a16) p2.1 (a9/a17) p2.2 ( a10/a18) p2.3 (a11/a19) p2.4 ( a12/a20) p2.5 ( a13/a21) p2.6 ( a14/a22) p2.7 ( a15/a23) 28 29 30 31 36 39 38 37 16 p3.0 (rxd) 17 p3.1 (txd) 18 p3.2 ( int0 ) 19 p3.3 ( int1 ) 22 p3.4 (t0/pwmclk) 23 p3.5 (t1) 24 25 p3.7 ( rd ) p3.6 ( wr ) 12-bit voltage output dac 2 data pointers 11-bit stack pointer pwm0 pwm1 pwm control 1 2 32 42 ale 15 reset 48 dv dd 34 47 uart timer * pin numbers refer to the 52-lead mqfp package shaded areas represent the new features of the aduc834 over the aduc824 dual 16-bit - dac dual 16-bit pwm mux dac control por figure 1. detailed block diagram pin function descriptions pin no. pin no. 52-lead 56-lead mqfp csp mnemonic type * description 1, 2 56, 1 p1.0/p1.1 i/o p1.0 and p1.1 can function as a digital inputs or digital outputs and have a pull-up configu ration as described below for port 3. p1.0 and p1.1 have an increased current drive sink capa bility of 10 ma. p1.0/t2/pwm0 i/o p1.0 and p1.1 also have various secondary functions as described below. p1.0 can also be used to provide a clock input to ti mer 2. when enabled, counter 2 is incremented in response to a negative transition on the t2 input pin. if the pwm is enabled, the pwm0 output will appear at this pin. p1.1/t2ex/pwm1 i/o p 1.1 can also be used to provide a control input to timer 2. w hen enabled, a negative transition on the t2ex input pin will cause a timer 2 capture or reload event. if the pwm is enabled, the pwm1 output will appear at this pin.
rev. 0 aduc834 ?1 pin function descriptions (continued) pin no. pin no. 52-lead 56-lead mqfp csp mnemonic type * description 3?, 2?, p1.2?1.7 i port 1.2 to port 1.7 have no digital output driver; they can function as a digital 9?2 11?4 input for which ??must be written to the port bit. as a di gital inpu t, these pins must be drive n high or low externally. these pins also have the following analog functionality: p1.2/dac/iexc1 i/o the voltage output from the dac or one or both current sources (200 a or 2 200 a) can be configured to a ppear at this pin. p1.3/ain5/iexc2 i/o auxiliary adc input or one or both current sources can be configured at this pin. p1.4/ain1 i primary adc, positive analog input p1.5/ain2 i primary adc, negative analog input p1.6/ain3 i auxiliary adc input or muxed primary adc, positive analog input p1.7/ain4/dac i/o auxiliary adc input or muxed primary adc, negative analog input. the voltage output from the dac can also be configured to appear at this pin. 5 4, 5 av dd sa nalog supply voltage, 3 v or 5 v 6 6, 7, 8 agnd s analog ground. ground reference pin for the analog circuitry. 79 refin(? i reference input, negative terminal 81 0 refin(+) i reference input, positive terminal 13 15 ss i slave select input for the spi interface. a weak pull-up is present on this pin. 14 16 miso i/o master input/sl ave output for the spi interface. there is a weak pull-up on this input pin. 15 17 reset i reset input. a high level on this pin for 16 core clock cycles while the oscillator is running resets the device. there is an internal weak pull-down and a schmitt trigger input stage on this pin. 16?9, 18?1, p3.0?3.7 i/o bidirectional port pins with internal pull-up resistors. port 3 pins that have 1s written 22?5 24?7 to them are pulled high by the internal pull-up resistors, and in that state can be used as inputs. as inputs, port 3 pins being pulled externally low will source current because of the internal pull-up resistors. when driving a 0-to-1 out put transition, a strong pull-up is active for two core clock periods of the instruction cycle. port 3 pins also have various secondary functions including: p3.0/rxd i/o re ceiver dat a for uart serial port p3.1/txd i/o tr ansmitter data for uart serial port p3.2/ int0 i/o external interrupt 0. this pin can also be used as a gate control input to timer 0. p3.3/ int1 i/o external interrupt 1. this pin can also be used as a gate control input to timer 1. p3.4/t0/ i/o timer/counter 0 external input. if the pwm is enabled, an external clock may be pwmclk input at this pin. p3.5/t1 i/o timer/counter 1 external input p3.6/ wr i/o external data memory write strobe. l atches the data byte from port 0 into an external data memory. p3.7/ rd i/o external data memory read strobe. enables the data from an external data memory to port 0. 20, 34, 48 22, 36, 51 dv dd sd igital supply, 3 v or 5 v. 21, 35, 23, 37, dgnd s digital ground. ground reference point for the digital circuitry. 47 38, 50 26 sclock i/o serial interface clock for either the i 2 c or spi interface. as an input, this pin is a schmitt-triggered input and a weak in ternal pull-up is pres ent on th is pi n unless it is outputting logic low. this pin can also be directly controlled in software as a digital output pin. 27 mosi/sdata i/o serial data i/o for the i 2 c interface or master output/slave input for the spi interface. a weak internal pull-up is pres ent on this pin unless it is outputting logic low. this pin can also be directly controlled in software as a digital output pin.
rev. 0 ?2 aduc834 pin function descriptions (continued) pin no. pin no. 52-lead 56-lead mqfp csp mnemonic type * description 28?1 30?3 p2.0?2.7 i/o port 2 is a bidirectional port with internal pull-up resistors. port 2 pins that have 1s 36?9 39?2 (a8?15) written to them are pulled high by the internal pull-up resistors, and in that state can (a16?23) be used as inputs. as inputs, port 2 pins being pulled externally low will source current because of the internal pull-up resistors. port 2 emits the high order address bytes during fetches from external program memory and middle and high order address bytes during accesses to the 24-bit external data memory space. 32 34 xtal1 i input to the crystal oscillator inverter 33 35 xtal2 o output from the crystal oscillator inverter. (see ?ardware design considerations for description.) 40 43 ea i/o external access enable, logic input. when held high, this input enables the device to fetch code from internal program memory locations 0000h to f7ffh. when held low, this input enables the device to fetch all instructions from external program memory. to determine the mode of code execution, i.e., internal or external, the ea pin is sampled at the end of an external reset assertion or as part of a device power cycle. ea may also be used as an external emulation i/o pin, and therefore the voltage level at this pin must not be changed during normal mode operation as it may cause an emulation interrupt that will halt code execution. 41 44 psen op rogram store enable, logic output. this output is a control signal that enables the external program memory to the bus during external fetch operations. it is active every six oscillator periods except during external data memory accesses. this pin remains high during internal program execution. psen can also be used to enable serial download mode when pulled low through a resistor at the end of an external reset assertion or as part of a device power cycle. 42 45 ale o address latch enable, logic output. this output is used to latch the low byte (and page byte for 24-bit data address space accesses) of the address to external memory during external code or data memory access cycles. it is activated every six oscillator periods except during an external data memory access. it can be disabled by setting the pcon.4 bit in the pcon sfr. 43?6 46?9 p0.0?0.7 i/o p0.0?0.7, these pins are part of port0, which is an 8-bit, open-drain, bidirectional 49?2 52?5 (ad0?d3) i/o port. port 0 pins that have 1s written to them float and in that state can be used (ad4?d7) as high impedance inputs. an external pull-up resistor will be required on p0 outputs to force a valid logic high level externally. port 0 is also the multiplexed low-order address and databus during accesses to external program or data memory. in this application, it uses strong internal pull-ups when emitting 1s. * i = input, o = output, s = supply.
rev. 0 aduc834 ?3 memory organization the aduc834 contains four different memory blocks, namely: ?62 kbytes of on-chip flash/ee program memory ?4 kbytes of on-chip flash/ee data memory ?256 bytes of general-purpose ram ?2 kbytes of internal xram (1) flash/ee program memory the aduc834 provides 62 kbytes of flash/ee program memory to run user code. the user can choose to run code from this internal memory or run code from an external program memory. if the user applies power or resets the device while the ea pin is pulled low externally, the part will execute code from the external program space; otherwise, if ea is pulled high externally, the part defaults to code execution from its internal 62 kbytes of flash/ee program memory. unlike the aduc824, where code execution can overflow from the internal code space to external code space once the pc becomes greater than 1fffh, the aduc834 does not support the rollover from f7ffh in internal code space to f800h in external code space. instead, the 2048 bytes between f800h and ffffh will appear as nop instructions to user code. permanently embedded firmware allows code to be serially downloaded to the 62 kbytes of internal code space via the uart serial port while the device is in-circuit. no external hardware is required. 56 kbytes of the program memory can be reprogrammed during runtime; thus the code space can be upgraded in the field using a user defined protocol or it can be used as a data memory. this will be discussed in more detail in the flash/ee memory section of the data sheet. (2) flash/ee data memory 4 kb ytes of flash/ee data memory are available to the user and can be accessed indirectly via a group of registers mapped into the special function register (sfr) area. access to the flash/ee data memory is discussed in detail later as part of the flash/ee memory section in this data sheet. (3) general-purpose ram the general-purpose ram is divided into two separate memories, namely the upper and the lower 128 bytes of ram. the lower 128 bytes of ram can be accessed through direct or indirect addressing; the upper 128 bytes of ram can only be accessed through indirect addressing as it shares the same address space as the sfr space, which can only be accessed through direct addressing. the lower 128 bytes of internal data memory are mapped as shown in figure 2. the lowest 32 bytes are grouped into four banks of eight registers addressed as r0 through r7. the next 16 bytes (128 bits), locations 20h through 2fh above the register banks, form a block of directly addressable bit locations at bit addresses 00h through 7fh. the stack can be located anywhere in the internal memory address space, and the stack depth can be expanded up to 2048 bytes. reset initializes the stack pointer to location 07h. any call or push pre-increments the sp before loading the stack. therefore, loading the stack starts from locations 08h, which is also the first register (r0) of register bank 1. thus, if one is going to use more than one register bank, the stack pointer should be initialized to an area of ram not used for data storage. bit-addressable (bit addresses) four banks of eight registers r0?7 banks selected via bits in psw 11 10 01 00 07h 0fh 17h 1fh 2fh 7fh 00h 08h 10h 18h 20h reset value of stack pointer 30h general-purpose area figure 2. lower 128 bytes of internal data memory (4) internal xram the aduc834 contains 2 kbytes of on-chip extended data memory. this memory, although on-chip, is accessed via the movx instruction. the 2 kbytes of internal xram are mapped into the bottom 2 kb ytes of the external address space if the cfg834.0 bit is set. otherwise, access to the external data memory will occur just like a standard 8051. even with the cfg834.0 bit set, access to the external xram will occur once the 24-bit dptr is greater than 0007ffh. external data memory space (24-bit address space) 000000h ffffffh cfg834.0 = 0 external data memory space (24-bit address space) 000000h ffffffh cfg834.0 = 1 0007ffh 000800h 2 kbytes on-chip xram figure 3. internal and external xram general notes pertaining to this data sheet 1. set implies a logic 1 state and cleared implies a logic 0 state unless otherwise stated. 2. set and cleared also imply that the bit is set or automatically cleared by the aduc834 hardware unless otherwise stated. 3. user software should not write 1s to reserved or unimplemented bits as they may be used in future products. 4. any pin numbers used throughout this data sheet refer to the 52-lead mqfp package, unless otherwise stated.
rev. 0 ?4 aduc834 when accessing the internal xram, the p0 and p2 port pins, as well as the rd and wr strobes, will not be output as per a standard 8051 movx instruction. this allows the user to use these port pins as standard i/o. the upper 1792 bytes of the internal xram can be configured to be used as an extended 11-bit stack pointer. by default, the stack will operate exactly like an 8052 in that it will roll over from ffh to 00h in the general-purpose ram. on the aduc834 however, it is possible (by setting cfg834.7) to enable the 11-bit extended stack pointer. in this case, the stack will roll over from ffh in ram to 0100h in xram. the 11-bit stack pointer is visible in the sp and sph sfrs. the sp sfr is located at 81h as with a standard 8052. the sph sfr is located at b7h. the 3 lsbs of this sfr contain the three extra bits necessary to extend the 8-bit stack pointer into an 11-bit stack pointer. upper 1792 bytes of on-chip xram (data + stack for exsp = 1, data only for exsp = 0) 256 bytes of on-chip data ram (data + stack) lower 256 bytes of on-chip xram (data only) 00h ffh 00h 07ffh cfg834.7 = 0 cfg834.7 = 1 100h figure 4. extended stack pointer operation external data memory (external xram) just like a standard 8051 compatible core, the aduc834 can access external data memory using a movx instruction. the movx instruction automatically outputs the various control strobes required to access the data memory. the aduc834 however, can access up to 16 mbytes of external data memory. this is an enhancement of the 64 kbytes external data memory space available on a standard 8051 compatible core. the external data memory is discussed in more detail in the aduc834 hardware design considerations section. special function registers (sfrs) the sfr space is mapped into the upper 128 bytes of internal data memory space and accessed by direct addressing only. it provides an interface between the cpu and all on-chip periph- erals. a block diagram showing the programming model of the aduc834 via the sfr area is shown in figure 5. 128-byte special function register area 62 kbyte electrically reprogrammable nonvolatile flash/ee program memory 8051 compatible core other on-chip peripherals temp sensor current sources 12-bit dac serial i/o wdt, psm tic, pll dual - adcs 4 kbyte electrically reprogrammable nonvolatile flash/ee data memory 256 bytes ram 2k xram figure 5. programming model all registers, except the program counter (pc) and the four gen eral-purpose register banks, reside in the sfr area. the sfr registers include control, configuration, and data registers that provide an interface between the cpu and all on-chip peripherals. accumulator sfr (acc) acc is the accumulator register and is used for math operations including addition, subtraction, integer multiplication and division, and boolean bit manipulations. the mnemonics for accumulator- specific instructions refer to the accumulator as a. b sfr (b) the b register is used with the acc for multiplication and division operations. for other instructions, it can be treated as a general-purpose scratchpad register. data pointer (dptr) the data pointer is made up of three 8-bit registers, named dpp (page byte), dph (high byte) and dpl (low byte). these are used to provide memory addresses for internal and external code access and external data access. it may be manipulated as a 16-bit register (dptr = dph, dpl), although inc dptr instructions will automatically carry over to dpp, or as three independent 8-bit registers (dpp, dph, dpl). the aduc834 supports dual data pointers. refer to the dual data pointer section in this data sheet.
rev. 0 aduc834 ?5 table ii. pcon sfr bit designations bit name description 7s mod double uart baud rate 6 seripd spi power-down interrupt enable 5 int0pd int0 power-down interrupt enable 4 aleoff disable ale output 3 gf1 general-purpose flag bit 2 gf0 general-purpose flag bit 1p d power-down mode enable 0 idl idle mode enable aduc834 configuration sfr (cfg834) the cfg834 sfr contains the necessary bits to configure the internal xram and the extended sp. by default it configures the user into 8051 mode, i.e., extended sp is disabled, internal xram is disabled. sfr address afh power-on default value 00h bit addressable no table iii. cfg834 sfr bit designations bit name description 7 exsp extended sp enable. if this bit is set, the stack will roll over from sph/sp = 00ffh to 0100h. if this bit is clear, the sph sfr will be disabled and the stack will roll over from sp = ffh to sp = 00h 6 reserved for future use 5 reserved for future use 4 reserved for future use 3 reserved for future use 2 reserved for future use 1 reserved for future use 0 xramen xram enable bit. if this bit is set, the internal xram will be mapped into the lower 2 kbytes of the external address space. if this bit is clear, the internal xram will not be accessible and the external data memory will be mapped into the lower 2 kbytes of external data memory. (see figure 3.) stack pointer (sp and sph) the sp sfr is the stack pointer and is used to hold an internal ram address that is called the ?op of the stack.?the sp register is incremented before data is stored during push and call executions. while the stack may reside anywhere in on-chip ram, the sp register is initialized to 07h after a reset. this causes the stack to begin at location 08h. as mentioned earlier, the aduc834 offers an extended 11-bit stack pointer. the three ex tra bits to make up the 11-bit stack pointer are the 3 lsbs of the sph byte located at b7h. program status word (psw) the psw sfr contains several bits reflecting the current status of the cpu as detailed in table i. sfr address d0h power-on default value 00h bit addressable yes table i. psw sfr bit designations bit name description 7c yc arry flag 6a ca uxiliary carry flag 5f 0g eneral-purpose flag 4 rs1 register bank select bits 3 rs0 rs1 rs0 selected bank 000 011 102 113 2o vo verflow flag 1f 1g eneral-purpose flag 0p parity bit power control sfr (pcon) the pcon sfr contains bits for power-saving options and general-purpose status flags as shown in table ii. the tic (wake-up/rtc timer) can be used to accurately wake up the aduc834 from power-down at regular intervals. to use the tic to wake up the aduc834 from power-down, the osc_pd bit in the pllcon sfr must be clear and the tic must be enabled. sfr address 87h power-on default value 00h bit addressable no
rev. 0 ?6 aduc834 complete sfr map figure 6 shows a full sfr memory map and the sfr contents after reset. not used indicates unoccupied sfr loca- ti ons . unoccupied locations in the sfr address space are not spicon f8h 04h reserved reserved reserved reserved reserved reserved not used reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved reserved not used reserved reserved reserved reserved reserved dacl fbh 00h dach fch 00h daccon fdh 00h b f0h 00h i2ccon e8h 00h acc e0h 00h adcstat d8h 00h psw d0h 00h t2con 00h wdcon c0h 10h ip b8h 00h p3 b0h ffh ie a8h 00h p2 a0h ffh scon 98h 00h p1 90h ffh tcon 88h 00h p0 80h ffh e9h 55h of0l e1h 00h adc0l d9h 00h adcmode d1h 00h econ b9h 00h ieip2 a9h a0h timecon a1h 00h sbuf 99h 00h tmod 89h 00h sp 81h 07h eah 55h of0m e2h 00h adc0m dah 00h adc0con d2h 07h rcap2l cah 00h chipid c2h 2 h hthsec a2h 00h tl0 8ah 00h dpl 82h 00h ebh 53h of0h e3h 80h adc0h dbh 00h adc1con d3h 00h rcap2h cbh 00h sec a3h 00h tl1 8bh 00h dph 83h 00h reserved reserved reserved reserved reserved gn1l ech 9ah of1l e4h 00h adc1l dch 00h sf d4h 45h tl2 cch 00h edata1 bch 00h min a4h 00h th0 8ch 00h dpp 84h 00h reserved gn1h edh 59h of1h e5h 80h adc1h ddh 00h icon d5h 00h th2 cdh 00h edata2 bdh 00h hour a5h 00h th1 8dh 00h reserved eadrl c6h 00h edata3 beh 00h intval a6h 00h spidat f7h 00h psmcon dfh deh pllcon d7h 03h edata4 bfh 00h pcon 87h 00h gn0l gn0m gn0h c8h pwmcon cfg834 dpcon sph pwm0l pwm0h pwm1l pwm1h b1h 00h b4h 00h b3h 00h b2h 00h b7h 00h afh 00h aeh 00h a7h 00h eadrh c7h 00h t3con 9eh 00h reserved reserved t3fd 9dh 00h reserved reserved reserved reserved reserved reserved reserved reserved 22 2 2 11111 ispi ffh 0 wcol feh 0 spe fdh 0 spim fch 0 cpol fbh 0 cpha fah spr1 f9h 0 spr0 f8h 0 bits f7h 0 f6h 0 f5h 0 f4h 0 f3h 0 f2h f1h 0 f0h 0 bits mdo efh 0 eeh 0 edh 0 ech 0 i2cm ebh 0 eah e9h 0 e8h 0 bits e7h 0 e6h 0 e5h 0 e4h 0 e3h 0 e2h e1h 0 e0h 0 bits rdy0 dfh 0 rdy1 deh 0 cal ddh 0 noxref dch 0 err0 dbh 0 err1 dah d9h 0 d8h 0 bits cy d7h 0 ac d6h 0 f0 d5h 0 rsi d4h 0 rs0 d3h 0 ov d2h fi d1h 0 p d0h 0 bits tf2 cfh 0 exf2 ceh 0 rclk cdh 0 tclk cch 0 exen2 cbh 0 tr2 cah cnt2 c9h 0 cap2 c8h 0 bits pre2 c7h 0 pre1 c6h 0 pre0 c5h 0 c4h 1 wdir c3h 0 wds c2h wde c1h 0 wdwr c0h 0 bits bfh 0 padc beh 0 pt2 bdh 0 ps bch 0 pt1 bbh 0 px1 bah pt0 b9h 0 px0 b8h 0 bits rd b7h 1 wr b6h 1 t1 b5h 1 t0 b4h 1 int1 b3h 1 int0 b2h txd b1h 1 rxd b0h 1 bits ea afh eadc aeh et2 adh es ach 0 et1 abh 0 ex1 aah et0 a9h 0 ex0 a8h 0 bits a7h a6h a5h 1 a4h 1 a3h 1 a2h a1h 1 a0h 1 bits sm0 9fh 0 sm1 9eh 0 sm2 9dh 0 ren 9ch 0 tb8 9bh 0 rb8 9ah t1 99h 0 r1 98h 0 bits 97h 1 96h 1 95h 1 94h 1 93h 1 92h t2ex 91h 1 t2 90h 1 bits tf1 8fh 0 tr1 8eh 0 tf0 8dh 0 tr0 8ch 0 ie1 8bh 0 it1 8ah ie0 89h 0 it0 88h 0 bits 87h 1 86h 1 85h 1 84h 1 83h 1 82h 81h 1 80h 1 bits 1 1 0 1 0 1 1 0 0 0 0 0 0 0 pre3 000 0 11 mde mco mdi i2crs i2ctx i2ci 1 calibration coefficients are preconfigured at power-up to factory calibrated values. ie0 89h 0 it0 88h 0 tcon 88h 00h bit mnemonic bit bit address mnemonic reset default value sfr address these bits are contained in this byte. reset default bit value sfr map key: sfr note: sfrs whose addresses end in 0h or 8h are bit-addressable. 2 these sfrs maintain their prereset values after a reset if timecon.0 = 1. notes figure 6. special function register locations and their reset default values implemented; i.e., no register exists at this location. if an unoccu- pied location is read, an unspecified value is returned. sfr locations that are reserved for future use are shaded (reserved) and should not be accessed by user software.
rev. 0 aduc834 ?7 adcstat adc status register. holds general status of the primary and auxiliary adcs. adcmode adc mode register. controls general modes of operation for primary and auxiliary adcs. adc0con primary adc control register. controls specific configuration of primary adc. adc1con auxiliary adc control register. controls specific configuration of auxiliary adc. sf sinc filter register. configures the decima tion factor for the sinc 3 filter and thus the primary and auxiliary adc update rates. icon current source control register. allows user control of the various on-chip current source options. adc0l/m/h primary adc 24-bit conversion result is held in these three 8-bit registers. adc1l/h auxiliary adc 16-bit conversion result is held in these two 8-bit registers. of0l/m/h primary adc 24-bit offset calibration coefficient is held in these three 8-bit registers. of1l/h auxiliary adc 16-bit offset calibration coef ficient is held in these two 8-bit registers. gn0l/m/h primary adc 24-bit gain calibration coefficient is held in these three 8-bit registers. gn1l/h auxiliary adc 16-bit gain calibration coefficient is held in these two 8-bit registers. adcstat?adc status register) this sfr reflects the status of both adcs including data ready, calibration, and various (adc-related) error and warning condit ions including reference detect and conversion overflow/underflow flags. sfr address d8h power-on default value 00h bit addressable yes table iv. adcstat sfr bit designations bit name description 7 rdy0 ready bit for primary adc. set by hardware on completion of adc conversion or calibration cycle. cleared directly by the user or indirectly by write to the mode bits to start another primary adc conversion or calibration. the p rimary adc is inhibited from writing further results to its data or calibration registers until the rdy0 bit is cleared. 6 rdy1 ready b it for auxiliary adc. same definition as rdy0 referred to the auxiliary adc. 5 cal calibration status bit. set by hardware on completion of calibration. cleared indirectly by a write to the mode bits to start another adc conversi on or c alibra tion. 4 noxref no external reference bit (only active if primary or auxiliary adc is active). set to ind icate that one or both of the refin pins is floating or the applied voltage is below a specified threshold. when set, conversion results are clamped to all ones, if using external reference. cleared to indicate valid v ref . 3 err0 primary adc error bit. set by hardware to indicate that the result written to the primary adc data registers has been clamped to all zeros or all ones. after a calibration, this bit also flags error conditions that caused the calibra tion registers not to be written. cleared by a write to the mode bits to initiate a conversion or calibration. 2 err1 auxiliary adc error bit. same definition as err0 referred to the au xiliary adc. 1 reserved for future use 0 reserved for future use adc sfr interface both adcs are controlled and configured via a number of sfrs that are mentioned here and described in more detail in the following pages.
rev. 0 ?8 aduc834 adcmode (adc mode register) used to control the operational mode of both adcs. sfr address d1h power-on default value 00h bit addressable no table v. adcmode sfr bit designations bit name description 7 reserved for future use 6 reserved for future use 5 adc0en primary adc enable. set by the user to enable the primary adc and place it in the mode selected in md2?d0 below. cleared by the user to place the primary adc in power-down mode. 4 adc1en auxiliary adc enable. set by the user to enable the auxiliary adc and place it in the mode selected in md2?d0 below. cleared by the user to place the auxiliary adc in power-down mode. 3 reserved for future use 2 md2 primary and auxiliary adc mode bits. 1 md1 these bits select the operational mode of the enabled adc as follows: 0 md0 md2 md1 md0 0 00 adc power-down mode (power-on default) 0 01 idle mode. in idle mode, the adc filter and modulator are held in a reset state although the modulator clocks are still provided. 0 10 single conversion mode. in single conversion mode, a single conversion is performed on the enabled adc. on completion of the conversion, the adc data registers (adc0h/m/l and/or adc1h/l) are updated, the relevant flags in the adcstat sfr are written, and power-down is re-entered with the md2?d0 accordingly being written to 000. 0 11 continuous conversion. in continuous conversion mode, the adc data registers are regularly updated at the selected update rate (see sf register). 1 00 internal zero-scale calibration. internal short automatically connected to the enabled adc input(s). 1 01 internal full-scale calibration internal or external v ref (as determined by xref0 and xref1 bits in adc0/1con) is automatically connected to the enabled adc input(s) for this calibration. 1 10 system zero-scale calibration. user should connect system zero-scale input to the enabled adc input(s) as selected by ch1/ch0 and ach1/ach0 bits in the adc0/1con register. 1 11 system full-scale calibration. user should connect system full-scale input to the enabled adc input(s) as selected by ch1/ch0 and ach1/ach0 bits in the adc0/1con register. notes 1. any change to the md bits will immediately reset both adcs. a write to the md2? bits with no change is also treated as a res et. (see exception to this in note 3 below.) 2. if adc0con is written when adc0en = 1, or if adc0en is changed from 0 to 1, then both adcs are also immediately reset. in oth er words, the primary adc is given priority over the auxiliary adc and any change requested on the primary adc is immediately responded to. 3. on the other hand, if adc1con is written or if adc1en is changed from 0 to 1, only the auxiliary adc is reset. for example, i f the primary adc is continuously converting when the auxiliary adc change or enable occurs, the primary adc continues undisturbed. rather than allow the auxilia ry adc to operate with a phase difference from the primary adc, the auxiliary adc will fall into step with the outputs of the primary adc. the result is that the first conversion time for the auxiliary adc will be delayed up to three outputs while the auxiliary adc update rate is synchronized to the primary adc. 4. once adcmode has been written with a calibration mode, the rdy0/1 bits (adcstat) are immediately reset and the calibration co mmences. on completion, the appropriate calibration registers are written, the relevant bits in adcstat are written, and the md2? bits are reset to 00 0 to indicate the adc is back in power-down mode. 5. any calibration request of the auxiliary adc while the temperature sensor is selected will fail to complete. although the rdy 1 bit will be set at the end of the calibration cycle, no update of the calibration sfrs will take place and the err1 bit will be set. 6. calibrations are performed at maximum sf (see sf sfr) value guaranteeing optimum calibration operation.
rev. 0 aduc834 ?9 adc0con (primary adc control register) and adc1con (auxiliary adc control register) the adc0con and adc1con sfrs are used to configure the primary and auxiliary adc for reference and channel selection, unipolar or bipolar coding and, in the case of the primary adc, for range (the auxiliary adc operates on a fixed input range of v ref ). adc0con primary adc control sfr sfr address d2h power-on default value 07h bit addressable no adc1con auxiliary adc control sfr sfr address d3h power-on default value 00h bit addressable no table vi. adc0con sfr bit designations bit name description 7 reserved for future use 6 xref0 primary adc external reference select bit. set by user to enable the primary adc to use the external reference via refin(+)/refin(?. cleared by user to enable the primary adc to use the internal band gap reference (v ref = 1.25 v). 5 ch1 primary adc channel selection bits 4 ch0 written by the user to select the differential input pairs used by the primary adc as follows: ch1 ch0 positive input negative input 00 ain1 ain2 01 ain3 ain4 10 ain2 ain2 (internal short) 11 ain3 ain2 3 uni0 primary adc unipolar bit. set by user to enable unipolar coding, i.e., zero differential input will result in 000000h output. cleared by user to enable bipolar coding, i.e., zero differential input will result in 800000h output. 2 rn2 primary adc range bits. 1 rn1 written by the user to select the primary adc input range as follows: 0 rn0 rn2 rn1 rn0 selected primary adc input range (v ref = 2.5 v) 000 20 mv (0 mv?0 mv in unipolar mode) 001 40 mv (0 mv?0 mv in unipolar mode) 010 80 mv (0 mv?0 mv in unipolar mode) 011 160 mv (0 mv?60 mv in unipolar mode) 100 320 mv (0 mv?20 mv in unipolar mode) 101 640 mv (0 mv?40 mv in unipolar mode) 110 1.28 v (0 v?.28 v in unipolar mode) 111 2.56 v (0 v?.56 v in unipolar mode) table vii. adc1con sfr bit designations bit name description 7 reserved for future use 6 xref1 auxiliary adc external reference bit. set by user to enable the auxiliary adc to use the external reference via refin(+)/refin(?. cleared by user to enable the auxiliary adc to use the internal band gap reference. 5 ach1 auxiliary adc channel selection bits. 4 ach0 written by the user to select the single-ended input pins used to drive the auxiliary adc as follows: ach1 ach0 positive input negative input 00 ain3 agnd 01 ain4 agnd 10t emp sensor agnd (temp sensor routed to the adc input) 11 ain5 agnd 3 uni1 auxiliary adc unipolar bit. set by user to enable unipolar coding, i.e., zero input will result in 0000h output. cleared by user to enable bipolar coding, i.e., zero input will result in 8000h output. 2 reserved for future use 1 reserved for future use 0 reserved for future use notes 1. when the temperature sensor is selected, user code must select internal reference via xref1 bit above and clear the uni1 bit (adc1con.3) to select bipolar coding. 2. the temperature sensor is factory calibrated to yield conversion results 8000h at 0 c. 3. a +1 c change in temperature will result in a +1 lsb change in the adc1h register adc conversion result.
rev. 0 ?0 aduc834 adc0h/adc0m/adc0l (primary adc conversion result registers) these three 8-bit registers hold the 24-bit conversion result from the primary adc. sfr address adc0h high data byte dbh adc0m middle data byte dah adc0l low data byte d9h power-on default value 00h adc0h, adc0m, adc0l bit addressable no adc0h, adc0m, adc0l adc1h/adc1l (auxiliary adc conversion result registers) these two 8-bit registers hold the 16-bit conversion result from the auxiliary adc. sfr address adc1h high data byte ddh adc1l low data byte dch power-on default value 00h adc1h, adc1l bit addressable no adc1h, adc1l of0h/of0m/of0l (primary adc offset calibration registers * ) these three 8-bit registers hold the 24-bit offset calibration coefficient for the primary adc. these registers are configured at power-on with a factory default value of 800000h. however, these bytes will be automatically overwritten if an internal or system zero-s cale calibration of the primary adc is initiated by the user via md2? bits in the adcmode register. sfr address of0h primary adc offset coefficient high byte e3h of0m primary adc offset coefficient middle byte e2h of0l primary adc offset coefficient low byte e1h power-on default value 800000h of0h, of0m, of0l, respectively bit addressable no of0h, of0m, of0l of1h/of1l (auxiliary adc offset calibration registers * ) these two 8-bit registers hold the 16-bit offset calibration coefficient for the auxiliary adc. these registers are configured at power-on with a factory default value of 8000h. however, these bytes will be automatically overwritten if an internal or system zero-sca le cali- bration of the auxiliary adc is initiated by the user via the md2? bits in the adcmode register. sfr address of1h auxiliary adc offset coefficient high byte e5h of1l auxiliary adc offset coefficient low byte e4h power-on default value 8000h of1h and of1l, respectively bit addressable no of1h, of1l gn0h/gn0m/gn0l (primary adc gain calibration registers * ) these three 8-bit registers hold the 24-bit gain calibration coefficient for the primary adc. these registers are configured at power-on with a factory-calculated internal full-scale calibration coefficient. every device will have an individual coefficient. howeve r, these bytes will be automatically overwritten if an internal or system full-scale calibration of the primary adc is initiated by the user via md2? bits in the adcmode register. sfr address gn0h primary adc gain coefficient high byte ebh gn0m primary adc gain coefficient middle byte eah gn0l primary adc gain coefficient low byte e9h power-on default value configured at factory final test; see notes above. bit addressable no gn0h, gn0m, gn0l gn1h/gn1l (auxiliary adc gain calibration registers * ) these two 8-bit registers hold the 16-bit gain calibration coefficient for the auxiliary adc. these registers are configured at power-on with a factory-calculated internal full-scale calibration coefficient. every device will have an individual coefficient. howeve r, these bytes will be automatically overwritten if an internal or system full-scale calibration of the auxiliary adc is initiated by th e user via md2? bits in the adcmode register. sfr address gn1h auxiliary adc gain coefficient high byte edh gn1l auxiliary adc gain coefficient low byte ech power-on default value configured at factory final test; see notes above. bit addressable no gn1h, gn1l * these registers can be overwritten by user software only if mode bits md0? (adcmode sfr) are zero.
rev. 0 aduc834 ?1 sf (sinc filter register) the number in this register sets the decimation factor and thus the output update rate for the primary and auxiliary adcs. this sfr cannot be written by user software while either adc is active. the update rate applies to both primary and auxiliary adcs and is calculated as follows: f sf f adc mod = 1 3 1 8 where: f adc = adc output update rate f mod = modulator clock frequency = 32.768 khz sf = decimal value of sf register the allowable range for sf is 0dh to ffh. examples of sf values and corresponding conversion update rates ( f adc ) and conversion times ( t adc ) are shown in table viii. the power-on default value for the sf register is 45h, resulting in a default adc update rate of just under 20 hz. both adc inputs are chopped to minimize offset errors, which means that the settling time for a single conversion, or the time to a first conversion result in continuous conversion mode, is 2 t adc . as mentioned earlier, all calibration cycles will be carried out automatically with a maximum, i.e., ffh, sf value to ensure optimum calibration performance. once a calibration cycle has completed, the value in the sf register will be that programmed by user software. table viii. sf sfr bit designations sf(dec) sf(hex) f adc (hz) t adc (ms) 13 0d 105.3 9.52 69 45 19.79 50.34 255 ff 5.35 186.77 icon (current sources control register) used to control and configure the various excitation and burnout current source options available on-chip. sfr address d5h power-on default value 00h bit addressable no table ix. icon sfr bit designations bit name description 7 reserved for future use 6b ob urnout current enable bit. set by user to enable both transducer burnout current sources in the primary adc signal paths. cleared by user to disable both transducer burnout current sources. 5 adc1ic auxiliary adc current correction bit. set by user to allow scaling of the auxiliary adc by an internal current source calibration word. 4 adc0ic primary adc current correction bit. set by user to allow scaling of the primary adc by an internal current source calibration word. 3 i2pin * current source-2 pin select bit. set by user to enable current source-2 (200 a) to external pin 3 (p1.2/dac/iexc1). cleared by user to enable current source-2 (200 a) to external pin 4 (p1.3/ain5/iexc2). 2 i1pin * current source-1 pin select bit. set by user to enable current source-1 (200 a) to external pin 4 (p1.3/ain5/iexc2). cleared by user to enable current source-1 (200 a) to external pin 3 (p1.2/dac/iexc1). 1 i2en current source-2 enable bit. set by user to turn on excitation current source-2 (200 a). cleared by user to turn off excitation current source-2 (200 a). 0 i1en current source-1 enable bit. set by user to turn on excitation current source-1 (200 a). cleared by user to turn off excitation current source-1 (200 a). * both current sources can be enabled to the same external pin, yielding a 400 a current source.
rev. 0 ?2 aduc834 primary and auxiliary adc noise performance tables x, xi, and xii show the output rms noise in v and output peak-to-peak resolution in bits (rounded to the nearest 0.5 lsb) for some typical output update rates on both the primary and auxiliary adcs. the numbers are typical and are generated at a differential input voltage of 0 v. the output update rate is selected via the sinc filter (sf) sfr. it is important to note that the peak-to-peak resolution figures represent the resolution for which there will be no code flicker within a six-sigma limit. the quickstart development system pc software comes com plete with an adc noise evaluation tool. this tool can be easily used with the evaluation board to see these figures from silicon. table x. primary adc, typical output rms noise ( v) typical output rms noise vs. input range and update rate; output rms noise in v sf data update input range word rate (hz) 20 mv 40 mv 80 mv 160 mv 320 mv 640 mv 1.28 v 2.56 v 13 105.3 1.50 1.50 1.60 1.75 3.50 4.50 6.70 11.75 69 19.79 0.60 0.65 0.65 0.65 0.65 0.95 1.40 2.30 255 5.35 0.35 0.35 0.37 0.37 0.37 0.51 0.82 1.25 table xi. primary adc, peak-to-peak resolution (bits) peak-to-peak resolution vs. input range and update rate; peak-to-peak resolution in bits sf data update input range word rate (hz) 20 mv 40 mv 80 mv 160 mv 320 mv 640 mv 1.28 v 2.56 v 13 105.3 12 13 14 15 15 15.5 16 16 69 19.79 13.5 14 15 16 17 17.5 18 18.5 255 5.35 14 15 16 17 18 18.5 19 19.5 typical rms resolution vs. input range and update rate: rms resolution in bits * sf data update input range word rate (hz) 20 mv 40 mv 80 mv 160 mv 320 mv 640 mv 1.28 v 2.56 v 13 105.3 14.7 15.7 16.7 17.7 17.7 18.2 18.7 18.7 69 19.79 16.2 16.7 17.7 18.7 19.7 20.2 20.7 21.2 255 5.35 16.7 17.7 18.7 19.7 20.7 21.2 21.7 22.2 * based on a six-sigma limit, the rms resolution is 2.7 bits greater than the peak-to-peak resolution. table xii. auxiliary adc typical output rms noise vs. update rate * output rms noise in v sf data update input range word r ate (hz) 2.5 v 13 105.3 10.75 69 19.79 2.00 255 5.35 1.15 * adc converting in bipolar mode peak-to-peak resolution vs. update rate 1 peak-to-peak resolution in bits sf data update input range word rate (hz) 2.5 v 13 105.3 16 2 69 19.79 16 255 5.35 16 notes 1 adc converting in bipolar mode 2 in unipolar mode, peak-to-peak resolution at 105 hz is 15 bits.
rev. 0 aduc834 ?3 - modulator programmable digital filter - adc buffer agnd av dd refin(? refin(+) chop ain1 ain2 ain3 ain4 output average output scaling digtal output result written to adc0h/m/l sfrs pga chop output average as part of the chopping implementation, each data-word output from the filter is summed and averaged with its predecessor to null adc channel offset errors. - adc the - architecture ensures 24 bits no missing codes. the entire - adc is chopped to remove drift error. differential reference the external reference input to the aduc834 is differential and facilitates ratiometric operation. the external reference voltage is selected via the xref0 bit in adc0con. reference detect circuitry tests for open or shorted reference inputs. analog input chopping the inputs are alternately reversed through the conversion cycle. chopping yields excellent adc offset and offset drift performance. burnout currents two 100na burnout currents allow the user to easily detect if a transducer has burned out or gone open-circuit. analog multiplexer a differential multiplexer allows selection of three fully differential pair options and additional internal short option (a in2?in2). the multiplexer is controlled via the channel selection bits in adc0con. buffer amplifier the buffer amplifier presents a high impedance input stage for the analog inputs, allowing significant external source impedances. the modulator provides a high frequency 1-bit data stream (the output of which is also chopped) to the digital filter, the duty cycle of which represents the sampled analog input voltage. - modulator programmable digital filter the sinc 3 filter removes quantization noise introduced by the modulator. the update rate and bandwidth of this filter are programmable via the sf sfr. the ouput word from the digital filter is scaled by the calibration coefficients before being provided as the conversion result. output scaling programmable gain amplifier the programmable gain amplifier allows eight unipolar and eight bipolar input ranges from 20mv to 2.56v (ext v ref = 2.5v). mux primary and auxiliary adc circuit description overview the aduc834 incorporates two independent - adcs (primary and auxiliary) with on-chip digital filtering intended for the measure- ment of wide dynamic range, low frequency signals such as those in weigh-scale, strain gage, pressure transducer, or temperature measurement applications. primary adc this adc is intended to convert the primary sensor input. the input is buffered and can be programmed for one of eight input ranges from 20 mv to 2.56 v being driven from one of three differential input channel options ain1/2, ain3/4, or ain3/2. the input channel is internally buffered, allowing the part to handle significant source impedances on the analog input and allowing r/c filtering (for noise rejection or rfi reduction) to be placed on the analog inputs if required. on-chip burnout currents can also be turned on. these currents can be used to check that a transducer on the selected channel is still operational before attempting to take measurements. the adc employs a - conversion technique to realize up to 24 bits of no missing codes performance. the - modulator con- verts the sampled input signal into a digital pulse train whose duty cycle contains the digital information. a sinc 3 programmable low- pass filter is then employed to decimate the modulator output data stream to give a valid data conversion result at programmable output rates from 5.35 hz (186.77 ms) to 105.03 hz (9.52 ms). a chopping scheme is also employed to minimize adc offset errors. a block diagram of the primary adc is shown in figure 7. figure 7. primary adc block diagram
rev. 0 ?4 aduc834 mu x ain3 ain4 ain5 on-chip temperature sensor - modulator programmable digital filter - adc refin(? refin(+) chop output average output scaling digtal output result written to adc1h/l sfrs chop - adc the - architecture ensures 16 bits no missing codes. the entire - adc is chopped to remove drift errors. mux output average as part of the chopping implementation, each data-word output from the filter is summed and averaged with its predecessor to null adc channel offset errors. the modulator provides a high frequency 1-bit data stream (the output of which is also chopped) to the digital filter, the duty cycle of which represents the sampled analog input voltage. - modulator programmable digital filter the sinc 3 filter removes quantization noise introduced by the modulator. the update rate and bandwidth of this filter are programmable via the sf sfr. the ouput word from the digital filter is scaled by the calibration coefficients before being provided as the conversion result. output scaling analog input chopping the inputs are alternately reversed through the conversion cycle. chopping yields excellent adc offset and offset drift performance. differential reference the external reference input to the aduc834 is differential and facilitates ratiometric operation. the external reference voltage is selected via the xref1 bit in adc1con. reference detect circuitry tests for open or shorted reference inputs. analog multiplexer a differential multiplexer allows selection of three external single ended inputs or the on-chip temp. sensor. the multiplexer is controlled via the channel selection bits in adc1con. figure 8. auxiliary adc block diagram auxiliary adc the auxiliary adc is intended to convert supplementary inputs such as those from a cold junction diode or thermistor. this adc is not buffered and has a fixed input range of 0 v to 2.5 v (as suming an external 2.5 v reference). the single-ended inputs can be driven from ain3, ain4, or ain5 pins, or directly from the on-chip temperature sensor voltage. a block diagram of the auxiliary adc is shown in figure 8. analog input channels the primary adc has four associated analog input pins (labelled ain1 to ain4) that can be configured as two fully differential input channels. channel selection bits in the adc0con sfr detailed in table vi allow three combinations of differential pair selection as well as an additional shorted input option (ain2?in2). the auxiliary adc has three external input pins (labelled ain3 to ain5) as well as an internal connection to the on-chip temperature sensor. all inputs to the auxiliary adc are single-ended inputs referenced to the agnd on the part. channel selection bits in the adc1con sfr previously detailed in table vii allow selection of one of four inputs. two input multiplexers switch the selected input channel to the on-chip buffer amplifier in the case of the primary adc and directly to the - modulator input in the case of the auxiliary adc. when the analog input channel is switched, the settling time of the part must elapse before a new valid word is available from the adc.
rev. 0 aduc834 ?5 primary and auxiliary adc inputs the output of the primary adc multiplexer feeds into a high impedance input stage of the buffer amplifier. as a result, the pri- mary adc inputs can handle significant source impedances and are tailored for direct connection to external resistive-type sensors like strain gages or resistance temperature detectors (rtds). the auxiliary adc, however, is unbuffered, resulting in higher analog input current on the auxiliary adc. it should be noted that this unbuffered input path provides a dynamic load to the driving source. therefore, resistor/capacitor combinations on the input pins can cause dc gain errors depending on the output impedance of the source that is driving the adc inputs. analog input ranges the absolute input voltage range on the primary adc is restricted to between agnd + 100 mv to av dd ?100 mv. care must be taken in setting up the common-mode voltage and input voltage range so that these limits are not exceeded; otherwise there will be a degradation in linearity performance. the absolute input voltage range on the auxiliary adc is restricted to between agnd ?30 mv to av dd + 30 mv. the slightly negative absolute input voltage limit does allow the possibility of monitoring small signal bipolar signals using the single-ended auxiliary adc front end. programmable gain amplifier the output from the buffer on the primary adc is applied to the input of the on-chip programmable gain amplifier (pga). the pga can be programmed through eight different unipolar input ranges and bipolar ranges. the pga gain range is programmed via the range bits in the adc0con sfr. with the external reference select bit set in the adc0con sfr and an external 2.5 v reference, the unipolar ranges are 0 mv to 20 mv, 0 mv to 40 mv, 0 mv to 80 mv, 0 mv to 160 mv, 0 mv to 320 mv, 0 mv to 640 mv, 0 v to 1.28 v, and 0 to 2.56 v; the bipolar ranges are 20 mv, 40 mv, 80 mv, 160 mv, 320 mv, 640 mv, 1.28 v, and 2.56 v. these are the nominal ranges that should appear at the input to the on-chip pga. an adc range match- ing specification of 2 v (typ) across all ranges means that calibration need only be carried out at a single gain range and does not have to be repeated when the pga gain range is changed. typical matching across ranges is shown in figure 9. here, the primary adc is configured in bipolar mode with an external 2.5 v reference, while just greater than 19 mv is forced on its inputs. the adc continuously converts the dc input voltage at an update rate of 5.35 hz, i.e., sf = ffh. in total, 800 conver- sion results are gathered. the first 100 results are gathered with the primary adc operating in the 20 mv range. the adc range is then switched to 40 mv, 100 m ore conversion results are gathered, and so on until the last group of 100 sam ples is gathered with the adc configured in the 2.56 v range. from figure 9, the variation in the sample mean through each range, i.e., the range matching, is seen to be of the order of 2 v. the auxiliary adc does not incorporate a pga and is configured for a fixed single input range of 0 to v ref . 0 100 200 300 400 500 600 700 800 sample count adc input voltage ?mv 19.372 19.371 19.370 19.369 19.368 19.367 19.366 19.365 19.364 adc range 20mv 40mv 80mv 160mv 320mv 640mv 1.28v 2.56v figure 9. primary adc range matching bipolar/unipolar inputs the analog inputs on the aduc834 can accept either unipolar or bipolar input voltage ranges. bipolar input ranges do not imply that the part can handle negative voltages with respect to system agnd. unipolar and bipolar signals on the ain(+) input on the primary adc are referenced to the voltage on the respective ain() input. for example, if ain(? is 2.5 v and the primary adc is configured for an analog input range of 0 mv to 20 mv, the input voltage range on the ain(+) input is 2.5 v to 2.52 v. if ain(? is 2.5 v and the aduc834 is configured for an analog input range of 1.28 v, the analog input range on the ain(+) input is 1.22 v to 3.78 v (i.e., 2.5 v 1.28 v). as mentioned earlier, the auxiliary adc input is a single-ended input with respect to the system agnd. in this context, a bipolar signal on the auxiliary adc can only span 30 mv negative with respect to agnd before violating the voltage input limits for this adc. bipolar or unipolar options are chosen by programming the primary and auxiliary unipolar enable bits in the adc0con and adc1con sfrs respectively. this programs the relevant adc for either unipolar or bipolar operation. programming for either unipolar or bipolar operation does not change any of the input signal conditioning; it simply changes the data output coding and the points on the transfer function where calibrations occur. when an adc is configured for unipolar operation, the output coding is natural (straight) binary with a zero differ ential input voltage resulting in a code of 000 . . . 000, a mid scale voltage resulting in a code of 100 . . . 000, and a full-scale input voltage resulting in a code of 111 . . . 111. when an adc is configured for bipolar operation, the coding is offset binary with a negative full-scale voltage resulting in a code of 000 . . . 000, a zero differential voltage resulting in a code of 100 . . . 000, and a positive full-scale voltage resulting in a code of 111 . . . 111.
rev. 0 ?6 aduc834 reference input the aduc834? reference inputs, refin(+) and refin(?, provide a differential reference input capability. the common- mode range for these differential inputs is from agnd to av dd . the nominal reference voltage, v ref (refin(+) ?refin(?), for specified operation is 2.5 v with the primary and auxiliary reference enable bits set in the respective adc0con and/or adc1con sfrs. the part is also functional (although not specified for performance) when the xref0 or xref1 bits are 0, which enables the on-chip internal band gap reference. in this mode, the adcs will see the internal reference of 1.25 v, therefore halving all input ranges. as a result of using the internal reference voltage, a noticeable degradation in peak-to-peak resolution will result. therefore, for best performance, operation with an external reference is strongly recommended. in applications where the excitation (voltage or current) for the transducer on the analog input also drives the reference voltage for the part, the effect of the low frequency noise in the excitation source will be removed as the application is ratiometric. if the aduc834 is not used in a ratiometric application, a low noise reference should be used. recommended reference voltage sources for the aduc834 include the ad780, ref43, and ref192. it should also be noted that the reference inputs provide a high impedance, dynamic load. because the input impedance of each reference input is dynamic, resistor/capacitor combinations on these inputs can cause dc gain errors depending on the output impedance of the source that is driving the reference inputs. reference voltage sources, like those recommended above (e.g., ad780), will typically have low output impedances and therefore decoupling capacitors on the refin(+) input would be recommended. deriving the reference input voltage across an external resistor, as shown in figure 66, will mean that the refer- ence input sees a significant external source impedance. external decoupling on the refin(+) and refin(? pins would not be recommended in this type of circuit configuration. burnout currents the primary adc on the aduc834 contains two 100 na constant current generators, one sourcing current from av dd to ain(+), and one sinking from ain(? to agnd. the currents are switched to the selected analog input pair. both currents are either on or off, depending on the burnout current enable (bo) bit in the icon sfr (see table ix). these currents can be used to verify that an external transducer is still operational before attempting to take measurements on that channel. once the burnout cur- rents are turned on, they will flow in the external transducer circuit, and a measurement of the input voltage on the analog input channel can be taken. if the resultant voltage measured is full-scale, it indicates that the transducer has gone open-circuit. if the voltage measured is 0 v, it indicates that the transducer has short circuited. for normal operation, these burnout currents are turned off by writing a 0 to the bo bit in the icon sfr. the current sources work over the normal absolute input voltage range specifications. excitation currents the aduc834 also contains two identical, 200 a constant current sources. both source current from av dd to pin 3 (iexc1) or pin 4 (iexc2). these current sources are controlled via bits in the icon sfr shown in table ix. they can be configured to source 200 a individually to both pins or a combination of both currents, i.e., 400 a, to either of the selected pins. these current sources can be used to excite external resistive bridge or rtd sensors. reference detect the aduc834 includes on-chip circuitry to detect if the part has a valid reference for conversions or calibrations. if the voltage between the external refin(+) and refin(? pins goes below 0.3 v or either the refin(+) or refin(? inputs is open circuit, the aduc834 detects that it no longer has a valid reference. in this case, the noxref bit of the adcstat sfr is set to a 1. if the aduc834 is performing normal conversions and the noxref bit becomes active, the conversion results revert to all 1s. it is not necessary to continuously monitor the status of the noxref bit when performing conversions. it is only necessary to verify its status if the conversion result read from the adc data register is all 1s. if the aduc834 is performing either an offset or gain calibration and the noxref bit becomes active, the updating of the respec- tive calibration registers is inhibited to avoid loading incorrect coefficients to these registers, and the appropriate err0 or err1 bits in the adcstat sfr are set. if the user is concerned about verifying that a valid reference is in place every time a calibration is performed, the status of the err0 or err1 bit should be checked at the end of the calibration cycle. - modulator a - adc generally consists of two main blocks, an analog modulator and a digital filter. in the case of the aduc834 adcs, the analog modulators consist of a difference amplifier, an integrator block, a comparator, and a feedback dac as illustrated in figure 10. dac integrator analog input difference amp comparator high frequency bitstream to digital filter figure 10. - modulator simplified block diagram
rev. 0 aduc834 ?7 in operation, the analog signal sample is fed to the difference amplifier along with the output of the feedback dac. the difference between these two signals is integrated and fed to the comparator. the output of the comparator provides the input to the feedback dac so the system functions as a negative feedback loop that tries to minimize the difference signal. the digital data that represents the analog input voltage is contained in the duty cycle of the pulse train appearing at the output of the com- parator. this duty cycle data can be recovered as a data-word using a subsequent digital filter stage. the sampling frequency of the modulator loop is many times higher than the bandwidth of the input signal. the integrator in the modulator shapes the quantization noise (which results from the analog-to-digital conversion) so that the noise is pushed toward one-half of the modulator frequency. digital filter the output of the - modulator feeds directly into the digital filter. the digital filter then band-limits the response to a fre- quency significantly lower than one-half of the modulator frequency. in this manner, the 1-bit output of the comparator is translated into a band-limited, low noise output from the aduc834 adcs. the aduc834 filter is a low-pass, sinc 3 or (sin x/x)3 filter whose primary function is to remove the quantization noise introduced at the modulator. the cutoff frequency and decimated output data rate of the filter are programmable via the sf (sinc filter) sfr as described in table viii. figure 11 shows the frequency response of the adc channel at the default sf word of 69 dec or 45h, yielding an overall output update rate of just under 20 hz. it should be noted that this frequency response allows frequency components higher than the adc nyquist frequency to pass through the adc, in some cases without significant attenuation. these components may, therefore, be aliased and appear in-band after the sampling process. it should also be noted that rejection of mains-related frequency components, i.e., 50 hz and 60 hz, is seen to be at a level of >65 db at 50 hz and >100 db at 60 hz. this confirms the data sheet specifications for 50 hz/60 hz normal mode rejection (nmr) at a 20 hz update rate. 0203050708 090 100 110 frequency ?hz gain ?db 0 ?0 ?0 ?0 ?0 ?0 ?00 ?10 ?20 10 40 60 ?0 ?0 ?0 ?0 figure 11. filter response, sf = 69 dec the response of the filter, however, will change with sf word as can be seen in figure 12, which shows >90 db nmr at 50 hz and >70 db nmr at 60 hz when sf = 255 dec. 02030507 080 9 0 110 frequency ?hz gain ?db 0 ?0 ?0 ?0 ?0 ?0 ?00 ?10 ?20 10 40 60 ?0 ?0 ?0 ?0 figure 12. filter response, sf = 255 dec figures 13 and 14 show the nmr for 50 hz and 60 hz across the full range of sf word, i.e., sf = 13 dec to sf = 255 dec. 10 50 70 110 150 170 190 210 sf ?decimal gain ?db 0 ?0 ?0 ?0 ?0 ?0 ?00 ?10 ?20 30 90 130 ?0 ?0 ?0 ?0 230 250 figure 13. 50 hz normal mode rejection vs. sf 10 50 70 110 150 170 190 210 sf ?decimal gain ?db 0 ?0 ?0 ?0 ?0 ?0 ?00 ?10 ?20 30 90 130 ?0 ?0 ?0 ?0 230 250 figure 14. 60 hz normal mode rejection vs. sf
rev. 0 ?8 aduc834 adc chopping both adcs on the aduc834 implement a chopping scheme whereby the adc repeatedly reverses its inputs. the decimated digital output words from the sinc3 filters therefore have a positive offset and negative offset term included. as a result, a final summing stage is included in each adc so that each output word from the filter is summed and averaged with the previous filter output to produce a new valid output result to be written to the adc data sfrs. in this way, while the adc throughput or update rate is as discussed earlier and illustrated in table viii, the full settling time through the adc (or the time to a first conversion result), will actually be given by 2 t adc . the chopping scheme incorporated in the aduc834 adc results in excellent dc offset and offset drift specifications and is extremely beneficial in applications where drift, noise rejection, and optimum emi rejection are important factors. calibration the aduc834 provides four calibration modes that can be programmed via the mode bits in the adcmode sfr detailed in table v. in fact, every aduc834 has already been factory calibrated. the resultant offset and gain calibration coeffi- cients for both the primary and auxiliary adcs are stored on-chip in manufacturing-specific flash/ee memory locations. at power-on or after reset, these factory calibration coefficients are automatically downloaded to the calibration registers in the aduc834 sfr space. each adc (primary and auxiliary) has dedicated calibration sfrs, these have been described earlier as part of the general adc sfr description. however, the factory calibration values in the adc calibration sfrs will be overwrit- ten if any one of the four calibration options are initiated and that adc is enabled via the adc enable bits in adcmode. even though an internal offset calibration mode is described below, it should be recognized that both adcs are chopped. this chopping scheme inherently minimizes offset and means that an internal offset calibration should never be required. also, because factory 5 v/25 c gain calibration coefficients are auto- matically present at power-on, an internal full-scale calibration will only be required if the part is being operated at 3 v or at temperatures significantly different from 25 c. the aduc834 offers internal or system calibration facilities. for full calibration to occur on the selected adc, the calibration logic must record the modulator output for two different input conditions. these are zero-scale and full- scale points. these points are derived by performing a conversion on the different input voltages provided to the input of the modulator during calibration. the result of the zero-scale calibration conversion is stored in the offset calibration registers for the appropriate adc. the result of the full-scale calibration conversion is stored in the gain calibration regis ters for the appropriate adc. with these readings, the calibration logic can calculate the offset and the gain slope for the input-to-output transfer function of the converter. during an internal zero-scale or full-scale calibration, the respective zero-scale input and full-scale input are automatically connected to the adc input pins internally to the device. a system calibra- tion, however, expects the system zero-scale and system full-scale voltages to be applied to the external adc pins before the cali- bration mode is initiated. in this way, external adc errors are taken into account and minimized as a result of system calibration. it should also be noted that to optimize calibration accuracy, all aduc834 adc calibrations are carried out automatically at the slowest update rate. internally in the aduc834, the coefficients are normalized before being used to scale the words coming out of the digital filter. the offset calibration coefficient is subtracted from the result prior to the multiplication by the gain coefficient. from an operational point of view, a calibration should be treated like another adc conversion. a zero-scale calibration (if required) should always be carried out before a full-scale calibration. system software should monitor the relevant adc rdy0/1 bit in the adcstat sfr to determine end of calibra- tion via a polling sequence or interrupt driven routine. nonvolatile flash/ee memory flash/ee memory overview the aduc834 incorporates flash/ee memory technology on-chip to provide the user with nonvolatile, in-circuit reprogrammable, code and data memory space. flash/ee memory is a relatively recent type of nonvolatile memory technology and is based on a single transistor cell architecture. this technology is basically an outgrowth of eprom technology and was developed through the late 1980s. flash/ee memory takes the flexible in-circuit reprogrammable features of eeprom and combines them with the space efficient/density features of eprom. (see figure 15). because flash/ee technology is based on a single transistor cell architecture, a flash memory array, like eprom, can be imple- mented to achieve the space efficiencies or memory densities required by a given design.
rev. 0 aduc834 ?9 like eeprom, flash memory can be programmed in-system at a byte level, although it must first be erased; the erase being performed in page blocks. thus, flash memory is often and more correctly referred to as flash/ee memory. flash/ee memory technology space efficient/ density in-circuit reprogrammable eprom technology eeprom technology figure 15. flash/ee memory development overall, flash/ee memory represents a step closer to the ideal memory device that includes nonvolatility, in-circuit program- mability, high density, and low cost. incorporated in the aduc834, flash/ee memory technology allows the user to update program code space in-circuit, without the need to replace onetime programmable (otp) devices at remote operating nodes. flash/ee memory and the aduc834 the aduc834 provides two arrays of flash/ee memory for user applications. 62 kbytes of flash/ee program space are provided on-chip to facilitate code execution without any exter- nal discrete rom device requirements. the program memory can be programmed in-circuit, using the serial download mode provided, using conventional third party memory programmers, or via any user defined protocol in user download (uload) mode. a 4 kbyte flash/ee data memory space is also provided on-chip. this may be used as a general-purpose, nonvolatile scratchpad area. user access to this area is via a group of seven sfrs. this space can be programmed at a byte level, although it must first be erased in 4-byte pages. aduc834 flash/ee memory reliability the flash/ee program and data memory arrays on the aduc834 are fully qualified for two key flash/ee memory characteristics, namely flash/ee memory cycling endurance and flash/ee memory data retention. endurance quantifies the ability of the flash/ee memory to be cycled through many program, read, and erase cycles. in real terms, a single endurance cycle is composed of four independent, sequential events. these events are defined as: a. initial page erase sequence b. read/verify sequence c. byte program sequence d. second read/verify sequence in reliability qualification, every byte in both the program and data flash/ee memory is cycled from 00h to ffh until a first fail is recorded, signifying the endurance limit of the on-chip flash/ee memory. as indicated in the specification pages of this data sheet, the aduc834 flash/ee memory endurance qualification has been carried out in accordance with jedec specification a117 over the industrial temperature range of ?0 c, +25 c, +85 c, and +125 c. the results allow the specification of a minimum endurance figure over supply and temperature of 100,000 cycles, with an endurance figure of 700,000 cycles being typical of operation at 25 c. retention quantifies the ability of the flash/ee memory to retain its programmed data over time. again, the aduc834 has been qualified in accordance with the formal jedec retention life- time specification (a117) at a specific junction temperature (t j = 55 c). as part of this qualification procedure, the flash/ee memory is cycled to its specified endurance limit described above, before data retention is characterized. this means that the flash/ee memory is guaranteed to retain its data for its full specified retention lifetime every time the flash/ee memory is reprogrammed. it should also be noted that retention lifetime, based on an activation energy of 0.6 ev, will derate with t j as shown in figure 16. 40 60 70 90 t j junction temperature ? c retention ?years 250 200 150 100 50 0 50 80 110 300 100 adi specification 100 years min. at t j = 55 c figure 16. flash/ee memory data retention a single flash/ee memory endurance cycle
rev. 0 ?0 aduc834 flash/ee program memory the aduc834 contains a 64 kbyte array of flash/ee program memory. the lower 62 kbytes of this program memory is avail- able to the user, and can be used for program storage or indeed as additional nv data memory. the upper 2 kbytes of this flash/ee program memory array contain permanently embedded firmware, allowing in circuit serial download, serial debug and nonintrusive single pin emula tion. these 2 kbytes of embedded firmware also contain a power-on configuration routine that downloads factory calibrated coeffi- cients to the various calibrated peripherals (adc, temperature sensor, current sources, bandgap references and so on). this 2 kbyte embedded firmware is hidden from user code. attempts to read this space will read 0s, i.e., the embedded firmware appears as nop instructions to user code. in normal operating mode (power up default) the 62 kbytes of user flash/ee program memory appear as a single block. this block is used to store the user code as shown in figure 17. ffffh 0000h f800h f7ffh user program memory 62 kbytes of flash/ee program memory is available to the user. all of this space can be programmed from the permanently embedded download/debug kernel or in parallel programming mode. embedded download/debug kernel permanently embedded firmware allows code to be downloaded to any of the 62 kbytes of on-chip program memory. the kernel program appears as ?op?instructions to user code. 62 kbyte 2 kbyte figure 17. flash/ee program memory map in normal mode in normal mode, the 62 kbytes of flash/ee program memory can be programmed programmed in two ways, namely: (1) serial downloading (in-circuit programming) the aduc834 facilitates code download via the standard uart serial port. the aduc834 will enter serial download mode after a reset or power cycle if the psen pin is pulled low through an external 1 k w resistor. once in serial download mode, the hidden embedded download kernel will execute. this allows the user to download code to the full 62 kbytes of flash/ee program memory while the device is in circuit in its target application hardware. a pc serial download executable is provided as part of the aduc834 quickstart development system. appliction note uc004 fully describes the serial download protocol that is used by the embedded download kernel. this appliction note is available at www.analog.com/microconverter. (2) parallel programming the parallel programming mode is fully compatible with conven- tional third party flash or eeprom device programmers. a block diagram of the external pin configuration required to support parallel programming is shown in figure 18. in this mode, ports 0, and 2 operate as the external address bus interface, p3 operates as the external data bus interface and p1.0 operates as the write enable strobe. port 1.1, p1.2, p1.3, and p1.4 are used as a general configuration port that configures the device for various program and erase operations during parallel programming. table xiii. flash/ee memory parallel programming modes port 1 pins p1.4 p1.3 p1.2 p1.1 programming mode 0000 e rase flash/ee program, data, and security modes 1001 r ead device signature/id 1010 p rogram code byte 0010 p rogram data byte 1011 r ead code byte 0011 r ead data byte 1100 p rogram security modes 1101 r ead/verify security modes all other codes redundant v dd gnd p1.1 -> p1.4 psen reset p3 p0 p2 aduc834 5v program mode (see table xiii) gnd program data ( d0?7) program address ( a0?13) (p 2.0 = a0) (p 1.7 = a13) command enable p1.0 ea entry sequence v dd gnd p1.5 -> p1.7 timing figure 18. flash/ee memory parallel programming user download mode (uload) in figure 17 we can see that it was possible to use the 62 kbytes of flash/ee program memory available to the user as one single block of memory. in this mode all of the flash/ee memory is read only to user code. however, the flash/ee program memory can also be written to during runtime simply by entering uload mode. in uload mode, the lower 56 kbytes of program memory can be erased and reprogrammed by user software as shown in figure 19. uload mode can be used to upgrade your code in the field via any user defined download protocol. configuring the spi port on the aduc834 as a slave, it is possible to completely reprogram the 56 kbytes of flash/ee program memory in only 5 s econds. see application note uc007.
rev. 0 aduc834 ?1 alternatively uload mode can be used to save data to the 56 kbytes of flash/ee memory. this can be extremely useful in datalogging applications where the aduc834 can provide up to 60 kbytes of nv data memory on-chip (4 kbytes of dedicated flash/ee data memory also exist). the upper 6 kbytes of the 62 kbytes of flash/ee program memory is only programmable via serial download or parallel programming. this means that this space appears as read only to user code. therefore, it cannot be accidently erased or repro- grammed by erroneous code execution. this makes it very suitable to use the 6 kbytes as a bootloader. a bootload enable option exists in the serial downloader to ?lways run from e000h after reset.?if using a bootloader, this option is recom- mended to ensure that the bootloader always executes correct code after reset. programming the flash/ee program memory via uload mode is described in more detail in the description of econ and also in application note uc007. ffffh e000h dfffh 0000h user bootloader space the user bootloader space can be programmed in download/debug mode via the kernel but is read only when executing user code 6 kbyte f800h f7ffh user download space either the download/debug kernel or user code (in uload mode) can program this space. embedded download/debug kernel permanently embedded firmware allows code to be downloaded to any of the 62 kbytes of on-chip program memory. the kernel program appears as ?op?instructions to user code. 56 kbyte 2 kbyte 62 kbytes of user code memory figure 19. flash/ee program memory map in uload mode flash/ee program memory security the aduc834 facilitates three modes of flash/ee program memory security. these modes can be independently activated, restricting access to the internal code space. these security modes can be enabled as part of serial download protocol, as described in application note uc004, or via parallel program- ming. the aduc834 offers the following security modes: lock mode this mode locks the code memory, disabling parallel program- ming of the program memory. however, reading the memory in parallel mode and reading the memory via a movc command from external memory are still allowed. this mode is deactivated by initiating an ?rase code and data?command in serial down- load or parallel programming modes. secure mode this mode locks the code memory, disabling parallel program- ming of the program memory. reading/verifying the memory in parallel mode and reading the internal memory via a movc command from external memory is also disabled. this mode is deactivated by initiating an ?rase code and data?command in serial download or parallel programming modes. serial safe mode this mode disables serial download capability on the device. if serial safe mode is activated and an attempt is made to reset the part into serial download mode, i.e., reset asserted and deasserted with psen low, the part will interpret the serial download reset as a normal reset only. it will therefore not enter serial download mode, but only execute a normal reset sequence. serial safe mode can only be disabled by initiating an ?rase code and data?command in parallel programming mode.
rev. 0 ?2 aduc834 b yte 1 (0000h) edata1 sfr b yte 1 (0004h) b yte 1 (0008h) b yte 1 ( 000ch) b yte 1 (0 ff8h) b yte 1 (0 ffch) b yte 2 (0001h) edata2 sfr b yte 2 (0005h) b yte 2 (0009h) b yte 2 ( 000dh) b yte 2 (0 ff9h) b yte 2 (0 ffdh) b yte 3 (0002h) edata3 sfr b yte 3 (0006h) b yte 3 (000ah) b yte 3 (000eh) b yte 3 (0 ffah) b yte 3 (0 ffeh) b yte 4 (0003h) edata4 sfr b yte 4 (0007h) b yte 4 ( 000bh) b yte 4 ( 000fh) b yte 4 (0 ffbh) b yte 4 (0 fffh) 01h 00h 02h 03h 3feh 3ffh page address (ead rh/l) byte a ddresses are given in brackets using the flash/ee data memory the 4 kbytes of flash/ee data memory is configured as 1024 pages, each of 4 bytes. as with the other aduc834 peripherals, the interface to this memory space is via a group of registers mapped in the sfr space. a group of four data registers (edata1?) is used to hold the 4 bytes of data at each page. the page is addressed via the two registers eadrh and eadrl. finally, econ is an 8-bit control register that may be written with one of nine flash/ee memory access commands to trigger various read, write, erase, and verify functions. a block diagram of the sfr interface to the flash/ee data memory array is shown in figure 20. econ?lash/ee memory control sfr programming of either the flash/ee data memory or the flash/ee program memory is done through the flash/ee memory control sfr (econ). this sfr allows the user to read, write, erase or verify the 4 kbytes of flash/ee data memory or the 56 kbytes of flash/ee program memory. table xiv. econ?lash/ee memory commands command description command description econ value (normal mode) (power-on default) (uload mode) 01h results in 4 bytes in the flash/ee data memory, not implemented. use the movc instruction. read addressed by the page address eadrh/l, being read into edata 1 to 4. 02h results in 4 bytes in edata1? being written to the results in bytes 0?55 of internal xram being written write flash/ee data memory, at the page address given by to the 256 bytes of flash/ee program memory at the page eadrh. (0 eadrh < 0400h) address given by eadrh/l (0 eadrh/l < e0h) note: the 4 bytes in the page being addressed must note: the 256 bytes in the page being addressed must be pre-erased. be pre-erased. 03h reserved command reserved command 04h verifies if the data in edata1? is contained in the not implemented. use the movc and movx instructions verify page address given by eadrh/l. a subsequent read to verify the write in software. of the econ sfr will result in a 0 being read if the verification is valid, or a nonzero value being read to indicate an invalid verification. 05h results in the erase of the 4 bytes page of flash/ee data r esults in the 64- bytes page of flash/ee program memory, erase page memory addressed by the page address eadrh/l addressed by the byte address eadrh/l being erased. eadrl can equal any of 64 locations within the page. a new page starts whenever eadrl is equal to 00h, 40h, 80h, or c0h 06h results in the erase of entire 4 kbytes of flash/ee results in the erase of the entire 56 kbytes of uload erase all data memory. flash/ee program memory 81h results in the byte in the flash/ee data memory, not implemented. use the movc command. readbyte addressed by the byte address eadrh/l, being read into edata1. (0 eadrh/l 0fffh). 82h results in the byte in edata1 being written into results in the byte in edata1 being written into writebyte flash/ee data memory, at the byte address eadrh/l. flash/ee program memory at the byte address eadrh/l (0 eadrh/l dfffh) 0fh leaves the econ instructions to operate on the enters normal mode directing subsequent econ exuload flash/ee data memory. instructions to operate on the flash/ee data memory f0h enters uload mode, directing subsequent econ leaves the econ instructions to operate on the flash/ee uload instructions to operate on the flash/ee program memory. program memory. figure 20. flash/ee data memory control and configuration
rev. 0 aduc834 ?3 programming the flash/ee data memory a user wishes to program f3h into the second byte on page 03h of the flash/ee data memory space while preserving the other three bytes already in this page. a typical program of the flash/ee data array will involve: 1. setting eadrh/l with the page address 2. writing the data to be programmed to the edata1? 3. writing the econ sfr with the appropriate command step 1: set up the page address the two address registers eadrh and eadrl hold the high byte address and the low byte address of the page to be addressed. the assembly language to set up the address may appear as: mov eadrh,#0 ; set page address pointer mov eadrl,#03h step 2: set up the edata registers the four values to be written into the page into the 4 sfrs edata1?. unfortunately we do not know three of them. thus it is necessary to read the current page and overwrite the second byte. mov econ,#1 ; read page into edata1-4 mov edata2,#0f3h ; overwrite byte 2 step 3: program page a byte in the flash/ee array can only be programmed if it has previously been erased. to be more specific, a byte can only be programmed if it already holds the value ffh. because of the flash/ee architecture, this erase must happen at a page level. therefore, a minimum of 4 bytes (1 page) will be erased when an erase command is initiated. once the page is erased, we can program the 4 bytes in-page and then perform a verification of the data. mov econ,#5 ; erase page mov econ,#2 ; write page mov econ,#4 ; verify page mov a,econ ; check if econ=0 (ok!) jnz error note: although the 4 kbytes of flash/ee data memory is shipped from the factory pre-erased, i.e., byte locations set to ffh, it is nonetheless good programming practice to include an erase-all routine as part of any configuration/setup code running on the aduc834. an ?rase-all?command consists of writing ?6h?to the econ sfr, which initiates an erase of the 4-kbyte flash/ee array. this command coded in 8051 assembly would appear as: mov econ,#06h ; erase all command ; 2 ms duration flash/ee memory timing typical program and erase times for the aduc834 are as follows: normal mode (operating on flash/ee data memory) readpage (4 bytes) ?5 machine cycles writepage (4 bytes) ?380 s verifypage (4 bytes) ?5 machine cycles erasepage (4 bytes) ?2 ms eraseall (4 kbytes) ?2 ms readbyte (1 byte) ?3 machine cycles writebyte (1 byte) ?200 s uload mode (operating on flash/ee program memory) writepage (256 bytes) ?15 ms erasepage (64 bytes) ?2 ms eraseall (56 kbytes) ?2 ms writebyte (1 byte) ?200 s it should be noted that a given mode of operation is initiated as soon as the command word is written to the econ sfr. the core microcontroller operation on the aduc834 is idled until the requested program/read or erase mode is completed. in practice, this means that even though the flash/ee memory mode of operation is typically initiated with a two-machine cycle mov instruction (to write to the econ sfr), the next instruction will not be executed until the flash/ee operation is complete. this means that the core will not respond to interrupt requests until the flash/ee operation is complete, although the core peripheral functions like counter/timers will continue to count and time as configured throughout this period.
rev. 0 ?4 aduc834 dac the aduc834 incorporates a 12-bit, voltage output dac on-chip. it has a rail-to-rail voltage output buffer capable of driving 10 k w /100 pf. it has two selectable ranges, 0 v to v ref (the inter- nal bandgap 2.5 v reference) and 0 v to av dd . it can operate in 12-bit or 8-bit mode. the dac has a control register, daccon, and two data registers, dach/l. the dac output can be programmed to appear at pin 3 or pin 12. it should be noted that in 12-bit mode, the dac voltage output will be updated as soon as the dacl data sfr has been written; therefore, the dac data registers should be updated as dach first, followed by dacl. the 12-bit dac data should be written into dach/l right-justified such that dacl contains the lower eight bits, and the lower nibble of dach contains the upper four bits. table xv. daccon sfr bit designations bit name description 7 reserved for future use 6 reserved for future use 5 reserved for future use 4 dacpin dac output pin select. set by the user to direct the dac output to pin 12 (p1.7/ain4/dac). cleared by user to direct the dac output to pin 3 (p1.2/dac/iexc1). 3 dac8 dac 8-bit mode bit. set by user to enable 8-bit dac operation. in this mode, the 8-bits in dacl sfr are routed to the 8 msbs of the dac, and the 4 lsbs of the dac are set to zero. cleared by user to operate the dac in its normal 12-bit mode of operation. 2 dacrn dac output range bit. set by user to configure dac range of 0?v dd . cleared by user to configure dac range of 0 v?.5 v (v ref ). 1 dacclr dac clear bit. set to 1 by user to enable normal dac operation. cleared to 0 by user to reset dac data registers dacl/h to zero. 0 dacen dac enable bit. set to 1 by user to enable normal dac operation. cleared to 0 by user to power down the dac. dach/l dac data registers function dac data registers, written by user to update the dac output. sfr address dacl (dac data low byte) fbh dach (dac data high byte) fch power-on default value 00h both registers bit addressable no both registers using the d/a converter the on-chip d/a converter architecture consists of a resistor string dac followed by an output buffer amplifier, the func- tional equivalent of which is illustrated in figure 21. r r r r r aduc834 av dd v ref output buffer dac 12 high-z disable (from mcu) figure 21. resistor string dac functional equivalent features of this architecture include inherent guaranteed mono- tonicity and excellent differential linearity. as illustrated in figure 21, the reference source for the dac is user selectable in software. it can be either av dd or v ref . in 0-to-av dd mode, the dac output transfer function spans from 0 v to the voltage at the av dd pin. in 0-to-v ref mode, the dac output transfer function spans from 0 v to the internal v ref (2.5 v). the dac output buffer amplifier features a true rail-to-rail output stage implementation. this means that, unloaded, each output is capable of swinging to within less than 100 mv of both av dd and ground. moreover, the dac? linearity specification (when driving a 10 k w resistive load to ground) is guaranteed through the full transfer function except codes 0 to 48 in 0-to-v ref mode and 0 to 100 and 3950 to 4095 in 0-to-v dd mode. linearity degradation near ground and v dd is caused by saturation of the output amplifier, and a general representation of its effects (neglecting offset and gain error) is illustrated in figure 22. the dotted line in figure 22 indicates the ideal transfer function, and the solid line represents what the transfer function might look like with endpoint nonlinearities due to saturation of the output amplifier.
rev. 0 aduc834 ?5 note that figure 22 represents a transfer function in 0-to-v dd mode only. in 0-to-v ref mode (with v ref < v dd ), the lower nonlinearity would be similar, but the upper portion of the transfer function would follow the ?deal?line right to the end, showing no signs of endpoint linearity errors. v dd v dd ?0mv v dd ?00mv 100mv 50mv 0mv 000 hex fff hex figure 22. endpoint nonlinearities due to amplifier saturation the endpoint nonlinearities conceptually illustrated in figure 22 get worse as a function of output loading. most of the aduc834 data sheet specifications assume a 10 k w resistive load to ground at the dac output. as the output is forced to source or sink more current, the nonlinear regions at the top or bottom (respectively) of figure 22 become larger. with larger current demands, this can significantly limit output voltage swing. fi g ures 23 and 24 illustrate this behavior. it should be noted that the upper trace in each of these figures is only valid for an output range selection of 0-to-av dd . in 0-to-v ref mode, dac loading will not cause high-side voltage drops as long as the reference voltage remains below the upper trace in the corre- sponding figure. for example, if av dd = 3 v and v ref = 2.5 v, the high-side voltage will not be affected by loads less than 5 ma. but somewhere around 7 ma, the upper curve in figure 24 drops below 2.5 v (v ref ) indicating that at these higher currents, the output will not be capable of reaching v ref . source/sink current ?ma 5 0510 15 output voltage ?v 4 3 2 1 0 dac loaded with 0000 hex dac loaded with 0fff hex figure 23. source and sink current capability with v ref = av dd = 5 v source/sink current ?ma 4 0510 15 output voltage ?v 3 1 0 dac loaded with 0000 hex dac loaded with 0fff hex figure 24. source and sink current capability with v ref = v dd = 3 v for larger loads, the current drive capability may not be sufficient. in order to increase the source and sink current capability of the dac, an external buffer should be added, as shown in figure 25. aduc834 12 figure 25. buffering the dac output the dac output buffer also features a high impedance disable function. in the chip? default power-on state, the dac is disabled and its output is in a high impedance state (or ?hree- state? where they remain inactive until enabled in software. this means that if a zero output is desired during power-up or power-down transient conditions, a pull-down resistor must be added to each dac output. assuming this resistor is in place, the dac output will remain at ground potential whenever the dac is disabled.
rev. 0 ?6 aduc834 table xvi. pwmcon sfr bit designations bit name description 7 reserved for future use 6 md2 pwm mode bits 5 md1 the md2/1/0 bits choose the pwm mode as follows: 4 md0 md2 md1 md0 mode 0 00m ode 0: pwm disabled 0 01m ode 1: single variable resolution pwm 0 10m ode 2: twin 8-bit pwm 0 11m ode 3: twin 16-bit pwm 1 00m ode 4: dual nrz 16-bit - dac 1 01m ode 5: dual 8-bit pwm 1 10m ode 6: dual rz 16-bit - dac 1 11r eserved for future use 3c div1 pwm clock divider 2c div0 scale the clock source for the pwm counter as follows: cdiv1 cdiv0 description 00 pwm counter = selected clock /1 01 pwm counter = selected clock /4 10 pwm counter = selected clock /16 11 pwm counter = selected clock /64 1 csel1 pwm clock divider 0 csel0 select the clock source for the pwm as follows: csel1 csel0 description 00 pwm clock = f xtal /15 01 pwm clock = f xtal 10 pwm clock = external input at p3.4/t0/pwmclk 11 pwm clock = f vco (12.58 mhz) pulsewidth modulator (pwm) the pwm on the aduc834 is a highly flexible pwm offering programmable resolution and input clock, and can be config- ured for any one of six different modes of operation. two of these modes allow the pwm to be configured as a - dac with up to 16 bits of resolution. a block diagram of the pwm is shown in figure 26. clock select programmable divider compare mode pwm0h/l pwm1h/l 12.583mhz pwm clk 32.768khz 32.768khz/15 p1.0 p1.1 16-bit pwm counter figure 26. pwm block diagram the pwm uses five sfrs: the control sfr, pwmcon, and four data sfrs pwm0h, pwm0l, pwm1h, and pwm1l. pwmcon (as described below) controls the different modes of operation of the pwm as well as the pwm clock frequency. pwm0h/l and pwm1h/l are the data registers that determine the duty cycles of the pwm outputs at p1.0 and p1.1. to use the pwm user software, first write to pwmcon to select the pwm mode of operation and the pwm input clock. writing to pwmcon also resets the pwm counter. in any of the 16-bit modes of operation (modes 1, 3, 4, 6), user software should write to the pwm0l or pwm1l sfrs first. this value is written to a hidden sfr. writing to the pwm0h or pwm1h sfrs updates both the pwmxh and the pwmxl sfrs but does not change the outputs until the end of the pwm cycle in progress. the values written to these 16-bit registers are then used in the next pwm cycle. pwmcon pwm control sfr sfr address aeh power-on default value 00h bit addressable no
rev. 0 aduc834 ?7 pwm modes of operation mode 0: pwm disabled the pwm is disabled, allowing p1.0 and p1.1 be used as normal. mode 1: single-variable resolution pwm in mode 1, both the pulse length and the cycle time (period) are programmable in user code, allowing the resolution of the pwm to be variable. pwm1h/l sets the period of the output waveform. reducing pwm1h/l reduces the resolution of the pwm output but increases the maximum output rate of the pwm (e.g., setting pwm1h/l to 65536 gives a 16-bit pwm with a maximum output rate of 192 hz (12.583 mhz/65536). setting pwm1h/l to 4096 gives a 12-bit pwm with a maximum output rate of 3072 hz (12.583 mhz/4096)). pwm0h/l sets the duty cycle of the pwm output waveform, as shown in figure 27. p1.0 pwm counter pwm1h/l 0 pwm0h/l figure 27. pwm in mode 1 mode 2: twin 8-bit pwm in mode 2, the duty cycle of the pwm outputs and the resolution of the pwm outputs are both programmable. the m aximum resolution of the pwm output is eight bits. pwm1l sets the period for both pwm outputs. typically this will be set to 255 (ffh) to give an 8-bit pwm, although it is possible to reduce this as necessary. a value of 100 could be loaded here to give a percentage pwm (i.e., the pwm is accu- rate to 1%). the outputs of the pwm at p1.0 and p1.1 are shown in the diagram below. as can be seen, the output of pwm0 (p1.0) goes low when the pwm counter equals pwm0l. the output of pwm1 (p1.1) goes high when the pwm counter equals pwm1h and goes low again when the pwm counter equals pwm0h. setting pwm1h to 0 ensures that both pwm outputs start simultaneously. p1.1 p1.0 pwm counter pwm1h 0 pwm1l pwm0h pwm0l figure 28. pwm mode 2 mode 3: twin 16-bit pwm in mode 3, the pwm counter is fixed to count from 0 to 65536 giving a fixed 16-bit pwm. operating from the 12.58 mhz core clock results in a pwm output rate of 192 hz. the duty cycle of the pwm outputs at p1.0 and p1.1 are independently pro grammable. as shown below, while the pwm counter is less than pwm0h/l, the output of pwm0 (p1.0) is high. once the pwm counter equals pwm0h/l, then pwm0 (p1.0) goes low and remains low until the pwm counter rolls over. similarly, while the pwm counter is less than pwm1h/l, the output of pwm1 (p1.1) is high. once the pwm counter equals pwm1h/l, then pwm1 (p1.1) goes low and remains low until the pwm counter rolls over. in this mode, both pwm outputs are synchronized (i.e., once the pwm counter rolls over to 0, both pwm0 (p1.0) and pwm1 (p1.1) will go high). p1.1 p1.0 pwm counter pwm1h/l 0 65536 pwm0h/l figure 29. pwm mode 3
rev. 0 ?8 aduc834 mode 4: dual nrz 16-bit - dac mode 4 provides a high speed pwm output similar to that of a s - d dac. typically, this mode will be used with the pwm clock equal to 12.58 mhz. in this mode, p1.0 and p1.1 are updated every pwm clock (80 ns in the case of 12.58 mhz). over any 65536 cycles (16-bit pwm) pwm0 (p1.0) is high for pwm0h/l cycles and low for (65536 ?pwm0h/l) cycles. similarly pwm1 (p1.1) is high for pwm1h/l cycles and low for (65536 ?pwm1h/l) cycles. if pwm1h is set to 4010h (slightly above one quarter of fs), then typically p1.1 will be low for three clocks and high for one clock (each clock is approximately 80 ns). over every 65536 clocks, the pwm will compromise for the fact that the output should be slightly above one quarter of full scale by having a high cycle followed by only two low cycles. 12.583mhz 16-bit 80 s 80 s 0 16-bit 16-bit 16-bit 16-bit 16-bit carry out at p1.0 carry out at p1.1 pwm0h/l = c000h pwm1h/l = 4000h 00 1 000 latch 0 111 11 0 figure 30. pwm mode 4 for faster dac outputs (at lower resolution), write 0s to the lsbs that are not required with a 1 in the lsb position. if, for example, only 12-bit performance is required, write ?001?to the 4 lsbs. this means that a 12-bit accurate s - d dac output can occur at 3 khz. similarly, writing 00000001 to the 8 lsbs gives an 8-bit accurate s - d dac output at 49 khz. m ode 5: dual 8-bit pwm in mode 5, the duty cycle of the pwm outputs and the resolu- tion of the pwm outputs are individually programmable. the maximum resolution of the pwm output is eight bits. the output resolution is set by the pwm1l and pwm1h sfrs for the p1.0 and p1.1 outputs respectively. pwm0l and pwm0h sets the duty cycles of the pwm outputs at p1.0 and p1.1, respectively. both pwms have the same clock source and clock divider. p1.1 p1.0 pwm counters pwm1h 0 pwm1l pwm0h pwm0l figure 31. pwm mode 5 mode 6: dual rz 16-bit - dac mode 6 provides a high speed pwm output similar to that of a s - d dac. mode 6 operates very similarly to mode 4. however, the key difference is that mode 6 provides return to zero (rz) s - d dac output. mode 4 provides non-return-to-zero s - d dac outputs. the rz mode ensures that any difference in the rise and fall times will not affect the s - d dac inl. however, the rz mode halves the dynamic range of the s - d dac outputs from 0 av dd to 0 av dd /2. for best results, this mode should be used with a pwm clock divider of 4. if pwm1h is set to 4010h (slightly above one quarter of fs) then typically p1.1 will be low for three full clocks (3 80 ns), high for half a clock (40 ns) and then low again for half a clock (40 ns) before repeating itself. over every 65536 clocks, the pwm will compromise for the fact that the output should be slightly above one quarter of full scale by leaving the output high for two half clocks in four every so often. for faster dac outputs (at lower resolution), write 0s to the lsbs that are not required with a 1 in the lsb position. if, for example, only 12-bit performance is required, write ?001?to the 4 lsbs. this means that a 12-bit accurate s - d dac output can occur at 3 khz. similarly, writing 00000001 to the 8 lsbs gives an 8-bit accurate s - d dac output at 49 khz. 3.146mhz 16-bit 318 s 0 16-bit 16-bit 16-bit 16-bit 16-bit carry out at p1.0 carry out at p1.1 pwm0h/l = c000h pwm1h/l = 4000h 00 1 000 latch 0 111 11 0 318 s figure 32. pwm mode 6
rev. 0 aduc834 ?9 table xvii. pllcon sfr bit designations bit name description 7 osc_pd oscillator power-down bit. set by user to halt the 32 khz oscillator in power-down mode. cleared by user to enable the 32 khz oscillator in power-down mode. this feature allows the tic to continue counting even in power-down mode. 6 lock pll lock bit. this is a read-only bit. set automatically at power-on to indicate the pll loop is correctly tracking the crystal clock. after power down, this bit can be polled to wait for the pll to lock. cleared automatically at power-on to indicate the pll is not correctly tracking the crystal clock. this may be due to the absence of a crystal clock or an external crystal at power-on. in this mode, the pll output can be 12.58 mhz 20%. after the aduc834 wakes up from power-down, user code may poll this bit, to wait for the pll to lock. if lock = 0, then the pll is not locked. 5 reserved for future use; should be written with ? 4 ltea reading this bit returns the state of the external ea pin latched at reset or power-on. 3 fint fast interrupt response bit. set by user enabling the response to any interrupt to be executed at the fastest core clock frequency, regardless of the configuration of the cd2? bits (see below). after user code has returned from an interrupt, the core resumes code execution at the core clock selected by the cd2? bits. cleared by user to disable the fast interrupt response feature. 2 cd2 cpu (core clock) divider bits. 1 cd1 this number determines the frequency at which the microcontroller core will operate. 0 cd0 cd2 cd1 cd0 core clock frequency (mhz) 000 12.5 82912 001 6.291456 010 3.145728 011 1.572864 (default core clock frequency) 100 0.786432 101 0.393216 110 0.196608 111 0.098304 on-chip pll the aduc834 is intended for use with a 32.768 khz watch crystal. a pll locks onto a multiple (384) of this to provide a stable 12.582912 mhz clock for the system. the core can oper- ate at this frequency, or at binary submultiples of it, to allow power saving in cases where maximum core performance is not pllcon pll control register sfr address d7h power-on default value 03h bit addressable no required. the default core clock is the pll clock divided by 8 or 1.572864 mhz. the adc clocks are also derived from the pll clock, with the modulator rate being the same as the crys- tal oscillator frequency. the above choice of frequencies ensures that the modulators and the core will be synchronous, regardless of the core clock rate. the pll control register is pllcon.
rev. 0 ?0 aduc834 time interval counter (wake-up/rtc timer) a time interval counter (tic) is provided on-chip for: periodically waking the part up from power-down implementing a real-time clock counting longer intervals than the standard 8051 compatible timers are capable of the tic is capable of timeout intervals ranging from 1/128th second to 255 hours. furthermore, this counter is clocked by the crystal oscillator rather than the pll and thus has the ability to remain active in power-down mode and time long power-down intervals. this has obvious applications for remote battery-powered sensors where regular widely spaced readings are required. t he tic counter can easily be used to generate a real-time clock. the hardware will count in seconds, minutes, and hours; however, user software will have to count in days, months, and years. the current time can be written to the timebase sfrs (hthsec, sec, min, and hour) while tcen is low. when the rtc timer is enabled (tcen is set), the tcen bit itself and the hthsec, sec, min, and hour registers are not reset to 00h after a hardware or watchdog timer reset. this is to prevent the need to recalibrate the real-time clock after a reset. however, these registers will be reset to 00h after a power cycle (independent of tcen) or after any reset if tcen is clear. six sfrs are associated with the time interval counter, timecon being its control register. depending on the configuration of the it0 and it1 bits in timecon, the selected time counter register overflow will clock the interval counter. when this counter is equal to the time interval value loaded in the intval sfr, the tii bit (timecon.2) is set and generates an interrupt if enabled. (see ieip2 sfr description under inte rrupt system in this data sheet.) if the aduc834 is in power-down mode, again with tic interrupt enabled, the tii bit will wake up the device and resume code execution by vectoring directly to the tic interrupt service vector address at 0053h. the tic-related sfrs are described below with a block diagram of the tic shown in figure 33. 8-bit prescaler hundredths counter hthsec second counter sec minute counter min hour counter hour tien interval timeout time interval counter interrupt 8-bit interval counter intval sfr interval timebase selection mux tcen 32.768khz external crystal its0, 1 equal? figure 33. tic, simplified block diagram table xviii. timecon sfr bit designations bit name description 7 reserved for future use 6 reserved for future use. for future product code compatibility, this bit should be written as a ?. 5 its1 interval timebase selection bits 4 its0 written by user to determine the interval counter update rate. its1 its0 interval timebase 00 1/128 second 01 seconds 10 minutes 11 hours 3 sti single time interval bit. set by user to generate a single interval timeout. if set, a timeout will clear the tien bit. cleared by user to allow the interval counter to be automatically reloaded and start counting again at each interval timeout. 2 tii tic interrupt bit. set when the 8-bit interval counter matches the value in the intval sfr. cleared by user software. 1 tien time interval enable bit. set by user to enable the 8-bit time interval counter. cleared by user to disable and clear the contents of the 8-bit interval counter. to ensure that the 8-bit interval counter is cleared tien must be held low for at least 30.5 s (32 khz). 0 tcen time clock enable bit. set by user to enable the time clock to the time interval counters. cleared by user to disable the 32 khz clock to the tic and clear the 8-bit prescaler and the hthsec, sec, min and hours sfrs. to ensure that these registers are cleared, tcen must be held low for at least 30.5 s (32 khz). the time registers (hthsec, sec, min, and hour) can only be written while tcen is low.
rev. 0 aduc834 ?1 intval user time interval select register function user code writes the required time interval to this register. when the 8-bit interval counter is equal to the time interval value loaded in the intval sfr, the tii bit (timecon.2) is set and generates generates an interrupt if enabled. (see ieip2 sfr description under interrupt system in this data sheet.) sfr address a6h power-on default value 00h reset default value 00h bit addressable no valid value 0 to 255 decimal hthsec hundredths seconds time register function this register is incremented in (1/128) second intervals once tcen in timecon is active. the hthsec sfr counts from 0 to 127 before rolling over to increment the sec time register. sfr address a2h power-on default value 00h reset default value 00h if tcen = 0, previous value before reset if tcen = 1 bit addressable no valid value 0 to 127 decimal sec seconds time register function this register is incremented in 1-second intervals once tcen in timecon is active. the sec sfr counts from 0 to 59 before rolling over to increment the min time register. sfr address a3h power-on default value 00h reset default value 00h if tcen = 0, previous value before reset if tcen = 1 bit addressable no valid value 0 to 59 decimal min minutes time register function this register is incremented in 1-minute intervals once tcen in timecon is active. the min counts from 0 to 59 before rolling over to increment the hour time register. sfr address a4h power-on default value 00h reset default value 00h if tcen = 0, previous value before reset if tcen = 1 bit addressable no valid value 0 to 59 decimal hour hours time register function this register is incremented in 1-hour intervals once tcen in timecon is active. the hour sfr counts from 0 to 23 before rolling over to 0. sfr address a5h power-on default value 00h reset default value 00h if tcen = 0, previous value before reset if tcen = 1 bit addressable no valid value 0 to 23 decimal
rev. 0 ?2 aduc834 table xix. wdcon sfr bit designations bit name description 7 pre3 watchdog timer prescale bits. 6 pre2 the watchdog timeout period is given by the equation: t wd = (2 pre (2 9 /f pll )) 5 pre1 (0 pre 7; f pll = 32.768 khz) 4 pre0 pre3 pre2 pre1 pre0 timeout period (ms) action 00 00 15.6 reset or interrupt 00 01 31.2 reset or interrupt 00 10 62.5 reset or interrupt 00 11 125 reset or interrupt 01 00 250 reset or interrupt 01 01 500 reset or interrupt 01 10 1000 reset or interrupt 01 11 2000 reset or interrupt 10 00 0.0 immediate reset pre3? > 1001 reserved 3 wdir watchdog interrupt response enable bit. if this bit is set by the user, the watchdog will gener ate an interrupt response instead of a system reset when the watchdog timeout period has expired. this interrupt is not disabled by the clr ea instruction and it is also a fixed, high-prior ity interrupt. if the watchdog is not being used to monitor the system, it can alternatively be used as a timer. the prescaler is used to set the timeout period in which an interrupt will be generated. (see also note 1, table xxxix in the interrupt system section.) 2 wds watchdog status bit. set by the watchdog controller to indicate that a watchdog timeout has occurred. cleared by writing a 0 or by an external hardware reset. it is not cleared by a watchdog reset. 1 wde watchdog enable bit. set by user to enable the watchdog and clear its counters. if a 1 is not written to this bit within the watchdog timeout period, the watchdog will generate a reset or interrupt, depending on wdir. cleared under the following conditions, user writes 0, watchdog reset (wdir = 0); hardw are reset; psm interrupt. 0 wdwr watchdog write enable bit. to write data into the wdcon sfr involves a double instruction sequence. the wdwr bit must be set and the very next instruction must be a write instruction to the wdcon sfr. for example: clr ea ; disable int errupts while writing ; to wdt setb wdwr ; allow write to wdcon mov wdcon, #72h ; enable wdt for 2.0s timeout setb ea ; enable interrupts again (if rqd) watchdog timer the purpose of the watchdog timer is to generate a device reset or interrupt within a reasonable amount of time if the aduc834 enters an erroneous state, possibly due to a programming error, electrical noise, or rfi. the watchdog function can be disabled by clearing the wde (watchdog enable) bit in the watchdog control (wdcon) sfr. when enabled; the watchdog circuit will generate a system reset or interrupt (wds) if the user program fails to set the watchdog (wde) bit within a predetermined amount of time (see pre3? bits in wdcon). the watchdog timer itself is a 16-bit counter that is clocked at 32.768 khz. the watchdog timeout interval can be adjusted via the pre3? bits in wdcon. full control and status of the watchd og timer function can be controlled via the watchdog timer control sfr (wdcon). the wdcon sfr can only be written by user software if the double write sequence described in wdwr below is initiated on every write access to the wdcon sfr. wdcon watchdog timer control register sfr address c0h power-on default value 10h bit addressable yes
rev. 0 aduc834 ?3 psmcon power supply monitor control register sfr address dfh power-on default value deh bit addressable no power supply monitor as its name suggests, the power supply monitor, once enabled, monitors both supplies (av dd or dv dd ) on the aduc834. it will indicate when any of the supply pins drop below one of four user-selectable voltage trip points from 2.63 v to 4.63 v. for correct operation of the power supply monitor function, av dd must be equal to or greater than 2.7 v. monitor function is controlled via the psmcon sfr. if enabled via the ieip2 sfr, the monitor will interrupt the core using the psmi bit in the psmcon sfr. this bit will not be cleared until the failing power supply has returned above the trip point for at least 250 ms. this monitor function allows the user to save working registers to avoid possible data loss due to the low supply condition, and also ensures that normal code execution will not resume until a safe supply level has been well established. the supply monitor is also protected against spurious glitches triggering the interrupt circuit. table xx. psmcon sfr bit designations bit name description 7 cmpd dv dd comparator bit. this is a read-only bit and directly reflects the state of the dv dd comparator. read 1 indicates the dv dd supply is above its selected trip point. read 0 indicates the dv dd supply is below its selected trip point. 6cmpaav dd comparator bit. this is a read-only bit and directly reflects the state of the av dd comparator. read 1 indicates the av dd supply is above its selected trip point. read 0 indicates the av dd supply is below its selected trip point. 5 psmi power supply monitor interrupt bit. this bit will be set high by the microconverter if either cmpa or cmpd are low, indicating low analog or digital supply. the psmi bit can be used to interrupt the processor. once cmpd and/or cmpa return (and remain) high, a 250 ms counter is started. when this counter timesout, the psmi interrupt is cleared. psmi can also be written by the user. however, if either com parator output is low, it is not possible for the user to clear psmi. 4 tpd1 dv dd trip point selection bits. 3 tpd0 these bits select the dv dd trip point voltage as follows: tpd1 tpd0 selected dv dd trip point (v) 00 4. 63 01 3. 08 10 2. 93 11 2. 63 2 tpa1 av dd trip point selection bits. 1 tpa0 these bits select the av dd trip point voltage as follows: tpa1tpa0 selected av dd trip point (v) 00 4. 63 01 3. 08 10 2. 93 11 2. 63 0 psmen power supply monitor enable bit. set to 1 by the user to enable the power supply monitor circuit. cleared to 0 by the user to disable the power supply monitor circuit.
rev. 0 ?4 aduc834 serial peripheral interface the aduc834 integrates a complete hardware serial peripheral interface (spi) interface on-chip. spi is an industry-standard synchronous serial interface that allows eight bits of data to be synchronously transmitted and received simultaneously, i.e., full duplex. it should be noted that the spi pins sclock and mosi are multiplexed with the i 2 c pins sclock and sdata. the pins are controlled via the i2ccon sfr only if spe is clear. spi can be configured for master or slave operation and typically consists of four pins, namely: sclock (serial clock i/o pin), pin 26 the master clock (sclock) is used to synchronize the data being transmitted and received through the mosi and miso data lines. a single data bit is transmitted and received in each sclock period. therefore, a byte is transmitted/received after eight sclock periods. the sclock pin is configured as an output in master mode and as an input in slave mode. in master mode the bit-rate, polarity, and phase of the clock are controlled by the cpol, cpha, spr0, and spr1 bits in the spicon sfr (see table xxi). in slave mode the spicon register will have to be configured with the phase and polarity (cpha and cpol) as the master as for both master and slave mode the data is transmitted on one edge of the sclock signal and sampled on the other. miso (master in, slave out data i/o pin), pin 14 the miso (master in slave out) pin is configured as an input line in master mode and an output line in slave mode. the miso line on the master (data in) should be connected to the miso line in the slave device (data out). the data is transferred as byte-wide (8-bit) serial data, msb first. mosi (master out, slave in pin), pin 27 the mosi (master out slave in) pin is configured as an output line in master mode and an input line in slave mode. the mosi line on the master (data out) should be connected to the mosi line in the slave device (data in). the data is transferred as byte-wide (8-bit) serial data, msb first. ss (slave select input pin), pin 13 the slave select ( ss ) input pin is only used when the aduc834 is configured in spi slave mode. this line is active low. data is only received or transmitted in slave mode when the ss pin is low, allowing the aduc834 to be used in single master, multislave spi configurations. if cpha = 1, the ss input may be permanently pulled low. with cpha = 0, the ss input must be driven low before the first bit in a byte wide transmission or reception and return high again after the last bit in that byte wide transmission or reception. in spi slave mode, the logic level on the external ss pin (pin 13), can be read via the spr0 bit in the spicon sfr. the following sfr registers are used to control the spi interface. table xxi. spicon sfr bit designations bit name description 7 ispi spi interrupt bit. set by microconverter at the end of each spi transfer. cleared directly by user code or indirectly by reading the spidat sfr 6 wcol write collision error bit. set by microconverter if spidat is written to while an spi transfer is in progress. cleared by user code. 5 spe spi interface enable bit. set by user to enable the spi interface. cleared by user to enable the i 2 c interface. 4 spim spi master/slave mode select bit. set by user to enable master mode operation (sclock is an output). cleared by user to enable slave mode operation (sclock is an input). 3 cpol * clock polarity select bit. set by user if sclock idles high. cleared by user if sclock idles low. 2 cpha * clock phase select bit. set by user if leading sclock edge is to transmit data. cleared by user if trailing sclock edge is to transmit data. 1 spr1 spi bit-rate select bits. 0 spr0 these bits select the sclock rate (bit-rate) in master mode as follows: spr1 spr0 selected bit rate 00f core /2 01f core /4 10f core /8 11f core /16 in spi slave mode, i.e., spim = 0, the logic level on the external ss pin (pin 13), can be read via the spr0 bit. * the cpol and cpha bits should both contain the same values for master and slave devices.
rev. 0 aduc834 ?5 spidat spi data register function the spidat sfr is written by the user to transmit data over the spi interface or read by user code to read data just received by the spi interface. sfr address f7h power-on default value 00h bit addressable no using the spi interface depending on the configuration of the bits in the spicon sfr shown in table xxi, the aduc834 spi interface will transmit or receive data in a number of possible modes. figure 34 shows all possible aduc834 spi configurations and the timing rela- tionships and synchronization between the signals involved. also shown in this figure is the spi interrupt bit (ispi) and how it is triggered at the end of each byte-wide communication. sclock (cp ol = 1) sclock (cp ol = 0) (cpha = 1) (cpha = 0) sample input ispi flag data output ispi flag sample input data output ? msb bit 6 bit 5 ? bit 4 bit 3 bit 2 bit 1 lsb msb bit 6 bit 5 bit 4 bit 3 bit 2 bit 1 lsb ss figure 34. spi timing, all modes spi interface?aster mode in master mode, the sclock pin is always an output and generates a burst of eight clocks whenever user code writes to the spidat register. the sclock bit rate is determined by spr0 and spr1 in spicon. it should also be noted that the ss pin is not used in master mode. if the aduc834 needs to assert the ss pin on an external slave device, a port digital output pin should be used. in master mode, a byte transmission or reception is initiated by a write to spidat. eight clock periods are generated via the sclock pin and the spidat byte being transmitted via mosi. with each sclock period, a data bit is also sampled via miso. after eight clocks, the transmitted byte will have been completely transmitted and the input byte will be waiting in the input shift register. the ispi flag will be set automatically and an interrupt will occur if enabled. the value in the shift register will be latched into spidat. spi interface?lave mode in slave mode, the sclock is an input. the ss pin must also be driven low externally during the byte communication. trans- mission is also initiated by a write to spidat. in slave mode, a data bit is transmitted via miso and a data bit is received via mosi through each input sclock period. after eight clocks, the transmitted byte will have been completely transmitted and the input byte will be waiting in the input shift register. the ispi flag will be set automatically and an interrupt will occur if enabled. the value in the shift register will be latched into spidat only when the transmission/reception of a byte has been com- pleted. the end of transmission occurs after the eighth clock has been received, if cpha = 1 or when ss returns high if cpha = 0.
rev. 0 ?6 aduc834 three sfrs are used to control the i 2 c interface. these are described below. i2ccon i 2 c control register sfr address e8h power-on default value 00h bit addressable yes table xxii. i2ccon sfr bit designations bit name description 7 mdo i 2 c software master data output bit (master mode only). this data bit is used to implement a master i 2 c transmitter interface in software. data written to this bit will be outputted on the sdata pin if the data output enable (mde) bit is set. 6 mde i 2 c software master data output enable bit (master mode only). set by the user to enable the sdata pin as an output (tx). cleared by the user to enable sdata pin as an input (rx). 5 mco i 2 c software master clock output bit (master mode only). this data bit is used to implement a master i 2 c transmitter interface in software. data written to this bit will be outputted on the sclock pin. 4 mdi i 2 c software master data input bit (master mode only). this data bit is used to implement a master i 2 c receiver interface in software. data on the s data pin is latched into this bit on sclock if the data output enable (mde) bit is 0. 3 i2cm i 2 c master/slave mode bit. set by the user to enable i 2 c software master mode. cleared by user to enable i 2 c hardware slave mode. 2 i2crs i 2 c reset bit (slave mode only). set by the user to reset the i 2 c interface. cleared by user code for normal i 2 c operation. 1i 2ctx i 2 c direction transfer bit (slave mode only). set by the microconverter if the interface is transmitting. cleared by the microconverter if the interface is receiving. 0 i2ci i 2 c interrupt bit (slave mode only). set by the microconverter after a byte has been transmitted or received. cleared automatically when the user code reads the i2cdat sfr (see i2cdat below). i2cadd i 2 c address register function holds the i 2 c peripheral address for the part. it may be overwritten by the user code. application note uc001 at www.analog.com/microconverter describes the format of the i 2 c standard 7-bit address in detail. sfr address 9bh power-on default value 55h bit addressable no i2cdat i 2 c data register function the i2cdat sfr is written by the user to transmit data over the i 2 c interface or read by user code to read data just received by the i 2 c interface. accessing i2cdat automatically clears any pending i 2 c interrupt and the i2ci bit in the i2ccon sfr. user software should only access i2cdat once per interrupt cycle. sfr address 9ah power-on default value 00h bit addressable no * purchase of licensed i 2 c components of analog devices or one of its sublicensed associated companies conveys a license for the purchaser under the phi lips i 2 c patent rights to use these components in an i 2 c system provided that the system conforms to the i 2 c standard specification as defined by philips. i 2 c serial interface the aduc834 supports a fully licensed * i 2 c serial interface. the i 2 c interface is implemented as a full hardware slave and software master. sdata (pin 27) is the data i/o pin and sclock (p in 26) is the serial clock. these two pins are shared with the mosi and sclock pins of the on-chip spi interface. therefore the user can only enable one or the other interface at any given time (see spe in table xxi). application note uc001 describes the operation of this interface as implemented and is available from the microconverter website at www.analog.com/microconverter.
rev. 0 aduc834 ?7 the main features of the microconverter i 2 c interface are: only two bus lines are required; a serial data line (sdata) and a serial clock line (sclock). an i 2 c master can communicate with multiple slave devices. because each slave device has a unique 7-bit address then single master/slave relationships can exist at all times even in a multislave environment (figure 35). on-chip filtering rejects <50 ns spikes on the sdata and the sclock lines to preserve data integrity. dv dd i 2 c master i 2 c slave #1 i 2 c slave #2 figure 35. typical i 2 c system software master mode the aduc834 can be used as a i 2 c master device by configuring the i 2 c peripheral in master mode and writing software to output the data bit by bit, which is referred to as a software master. master mode is enabled by setting the i2cm bit in the i2ccon register. to transmit data on the sdata line, mde must be set to enable the output driver on the sdata pin. if mde is set then the sdata pin will be pulled high or low depending on whether the mdo bit is set or cleared. mco controls the sclock pin and is always configured as an output in master mode. in master mode, the sclock pin will be pulled high or low depending on the whether mco is set or cleared. to receive data, mde must be cleared to disable the output driver on sdata. software must provide the clocks by toggling the mco bit and read sdata pin via the mdi bit. if mde is cleared, mdi can be used to read the sdata pin. the value of the sdata pin is latched into mdi on a rising edge of sclock. mdi is set if the sdata pin was high on the last rising edge of sclock. mdi is clear if the sdata pin was low on the last rising edge of sclock. software must control mdo, mco, and mde appropriately to generate the start condition, slave address, acknowledge bits, data bytes, and stop conditions appropriately. these functions are provided in application note uc001. hardware slave mode after reset, the aduc834 defaults to hardware slave mode. the i 2 c interface is enabled by clearing the spe bit in spicon. slave mode is enabled by clearing the i2cm bit in i2ccon. the aduc834 has a full hardware slave. in slave mode, the i 2 c address is stored in the i2cadd register. data received or to be transmitted is stored in the i2cdat register. once enabled in i 2 c slave mode, the slave controller waits for a start condition. if the aduc834 detects a valid start condition, followed by a valid address, and by the r/ w bit, the i2ci inter- rupt bit will get automatically set by hardware. the i 2 c peripheral will only generate a core interrupt if the user has preconfigured the i 2 c interrupt enable bit in the ieip2 sfr as well as the global interrupt bit ea in the ie sfr, i.e., ; enabling i2c interrupts for the aduc834 mov ieip2,#01h ; enable i2c interrupt setb ea on the aduc834 an auto clear of the i2ci bit is implemented so this bit is cleared automatically on a read or write access to the i2cdat sfr. mov i2cdat, a ; i2ci auto-cleared mov a, i2cdat ; i2ci auto-cleared if for any reason the user tries to clear the interrupt more than once, i.e., access the data sfr more than once per interrupt, then the i 2 c controller will halt. the interface will then have to be reset using the i2crs bit. the user can choose to poll the i2ci bit or enable the interrupt. in the case of the interrupt, the pc counter will vector to 003bh at the end of each complete byte. for the first byte when the user gets to the i2ci isr, the 7-bit address and the r/ w bit will appear in the i2cdat sfr. the i2ctx bit contains the r/ w bit sent from the master. if i2ctx is set then the master would like to receive a byte. h ence the slave will transmit data by writing to the i2cdat register. if i2ctx is cleared, the master would like to transmit a byte. hence the slave will receive a serial byte. the software can interrogate the state of i2ctx to determine whether it should write to or read from i2cdat. once the aduc834 has received a valid address, hardware will hold sclock low until the i2ci bit is cleared by the software. this allows the master to wait for the slave to be ready before transmitting the clocks for the next byte. the i2ci interrupt bit will be set every time a complete data byte is received or transmitted provided it is followed by a valid ack. if the byte is followed by a nack, an interrupt is not generated. the aduc834 will continue to issue interrupts for each complete data byte transferred until a stop condition is received or the interface is reset. when a stop condition is received, the interface will reset to a state where it is waiting to be addressed (idle). similarly, if the interface receives a nack at the end of a sequence, it also returns to the default idle state. the i2crs bit can be used to reset the i 2 c interface. this bit can be used to force the inter- face back to the default idle state. it should be noted that there is no way (in hardware) to distin- guish between an interrupt generated by a received start + valid address and an interrupt generated by a received data byte. user software must be used to distinguish between these interrupts.
rev. 0 ?8 aduc834 table xxiii. dpcon sfr bit designations bit name description 7 reserved for future use 6 dpt data pointer automatic toggle enable. cleared by user to disable auto swapping of the dptr. set in user software to enable automatic toggling of the dptr after each movx or movc instruction. 5d p1m1 shadow data pointer mode 4d p1m0 these two bits enable extra modes of the shadow data pointer operation allowing for more compact and more efficient code size and execution. m1 m0 behavior of the shadow data pointer 00 8052 behavior 01 dptr is post-incremented after a movx or a movc instruction 10 dptr is post-decremented after a movx or movc instruction 11 dptr lsb is toggled after a movx or movc instruction (this instruction can be useful for moving 8-bit blocks to/from 16-bit devices) 3d p0m1 main data pointer mode 2d p0m0 these two bits enable extra modes of the main data pointer operation allowing for more compact and more efficient code size and execution. m1 m0 behavior of the main data pointer 00 8052 behavior 01 dptr is post-incremented after a movx or a movc instruction 10 dptr is post-decremented after a movx or movc instruction 11 dptr lsb is toggled after a movx or movc instruction (this instruction can be useful for moving 8-bit blocks to/from 16-bit devices) 1 this bit is not implemented to allow the inc dpcon instruction toggle the data pointer without incrementing the rest of the sfr. 0 dpsel data pointer select. cleared by user to select the main data pointer. this means that the contents of the main 24-bit dptr appears in the 3 sfrs dpl, dph, and dpp. set by the user to select the shadow data pointer. this means that the contents of the shadow 24-bit dptr appears in the 3 sfrs dpl, dph, and dpp. notes 1. this is the only place where the main and shadow data pointers are distinguished. everywhere else in this data sheet, whereve r the dptr is mentioned, operation on the active dptr is implied. 2. only movc/movx @dptr instructions are relevant above. movc/movx pc/@ri instructions will not cause the dptr to automatically post increment/decrement, and so on. to illustrate the operation of dpcon, the following code will copy 256 bytes of code memory at address d000h into xr am starting from address 0000h. the code uses 16 bytes and 2054 cycles. to perform this on a standard 8051 requires approximately 33 bytes and 7172 cycles (dep ending on how it is implemented). dual data pointer the aduc834 incorporates two data pointers. the second data pointer is a shadow data pointer and is selected via the data pointer control sfr (dpcon). dpcon also includes features such as automatic hardware post-increment and post-decrement, as well as automatic data pointer toggle. dpcon is described in table xxiii. dpcon data pointer control sfr sfr address a7h power-on default value 00h bit addressable no mov dptr,#0 ; main dptr = 0 mov dpcon,#55h ; select shadow dptr ; dptr1 increment mode, ; dptr0 increment mode ; dptr auto toggling on mov dptr,#0d000h ; shadow dptr = d000h moveloop: clr a movc a,@a+dptr ; get data ; post inc dptr ; swap to main dptr (data) movx @dptr,a ; put acc in xram ; increment main dptr ; swap to shad dptr (code) mov a, dpl jnz moveloop
rev. 0 aduc834 ?9 port 1 port 1 is also an 8-bit port directly controlled via the p1 sfr. the port 1 pins are divided into two distinct pin groupings p1.0 to p1.1 and p1.2 to p1.7. p1.0 and p1.1 p1.0 and p1.1 are bidirectional digital i/o pins with internal pull-ups. if p1.0 and p1.1 have 1s written to them via the p1 sfr, these pins are pulled high by the internal pull-up resistors. in this state, they can also be used as inputs. as input pins being externally pulled low, they will source current because of the internal pu ll- ups. with 0s written to them, both these pins will drive a logic low output voltage (v ol ) and will be capable of sinking 10 ma compared to the standard 1.6 ma sink capability on the other port pins. these pins also have various secondary functions described in table xxiv. the timer 2 alternate functions of p1.0 and p1.1 can only be activated if the corresponding bit latch in the p1 sfr contains a 1. otherwise, the port pin is stuck at 0. in the case of the pwm outputs at p1.0 and p1.1, the pwm outputs will overwrite anything written to p1.0 or p1.1. table xxiv. p1.0 and p1.1 alternate pin functions pin alternate function p1.0 t2 (timer/counter 2 external input) pwm0 (pwm0 output at this pin) p1.1 t2ex (timer/counter 2 capture/reload trigger) pwm1 (pwm1 output at this pin) figure 37 shows a typical bit latch and i/o buffer for a p1.0 or p1.1 port pin. no external memory access is required from either of these pins although internal pull-ups are present. read latch internal bus write to latch read pin d cl q q latch p1.x pin alternate output function dv dd internal pull-up * * see figure 38 for details of internal pull-up alternate input function figure 37. p1.0 and p1.1 bit latch and i/o buffer the internal pull-up consists of active circuitry as shown in figure 38. whenever a p1.0 or p1.1 bit latch transitions from low to high, q1 in figure 38 turns on for 2 oscillator periods to quickly pull the pin to a logic high state. once there, the weaker q3 turns on, thereby latching the pin to a logic high. if the pin is momentarily pulled low externally, q3 will turn off, but the very weak q2 will continue to source some current into the pin, attempting to restore it to a logic high. q from port latch 2 clk delay q1 dv dd q2 dv dd q3 dv dd px.x pin q4 figure 38. internal pull-up configuration 8052 compatible on-chip peripherals this section gives a brief overview of the various secondary peripheral circuits that are also available to the user on-chip. these remaining functions are mostly 8052 compatible (with a few additional features) and are controlled via standard 8052 sfr bit definitions. parallel i/o the aduc834 uses four input/output ports to exchange data with external devices. in addition to performing general-purpose i/o, some ports are capable of external memory operations while others are multiplexed with alternate functions for the peripheral features on the device. in general, when a peripheral is enabled, that pin may not be used as a general-purpose i/o pin. port 0 port 0 is an 8-bit open-drain bidirectional i/o port that is directly controlled via the port 0 sfr. port 0 is also the multiplexed low order address and databus during accesses to external program or data memory. figure 36 shows a typical bit latch and i/o buffer for a port 0 port pin. the bit latch (one bit in the port? sfr) is represented as a type d flip-flop, which will clock in a value from the internal bus in response to a ?rite to latch?signal from the cpu. the q output of the flip-flop is placed on the internal bus in response to a ?ead latch?signal from the cpu. the level of the port pin itself is placed on the internal bus in response to a ?ead pin?signal from the cpu. some instructions that read a port activate the ?ead latch?signal, and others activate the ?ead pin?signal. see the following read-modify-write instructions section for more details. control read latch internal bus write to latch read pin d cl q q latch dv dd addr/data p0.x pin figure 36. port 0 bit latch and i/o buffer as shown in figure 36, the output drivers of port 0 pins are switchable to an internal addr and addr/data bus by an internal control signal for use in external memory accesses. during external memory accesses, the p0 sfr gets 1s written to it (i.e., all of its bit latches become 1). when accessing external memory, the control signal in figure 36 goes high, enabling push-pull operation of the output pin from the internal address or databus (addr/data line). therefore, no external pull-ups are required on port 0 in order for it to access external memory. in general-purpose i/o port mode, port 0 pins that have 1s written to them via the port 0 sfr will be configured as open- drain and will therefore float. in this state, port 0 pins can be used as high impedance inputs. this is represented in figure 36 by the nand gate whose output remains high as long as the control signal is low, thereby disabling the top fet. exter- nal pull-up resistors are therefore required when port 0 pins are used as general-purpose outputs. port 0 pins with 0s written to them will drive a logic low output voltage (v ol ) and will be capable of sinking 1.6 ma.
rev. 0 ?0 aduc834 p1.2 to p1.7 the remaining port 1 pins (p1.2?1.7) can only be configured as analog input (adc) or digital input pins. by (power-on) default, these pins are configured as analog inputs, i.e., ??written in the corresponding port 1 register bit. to configure any of these pins as digital inputs, the user should write a ??to these port bits to configure the corresponding pin as a high impedance digital input. figure 39 illustrates this function. note that there are no output drivers for port 1 pins, and they therefore cannot be used as outputs. read latch internal bus write to latch read pin d cl q q latch p1.x pin to adc figure 39. p1.2 to p1.7 bit latch and i/o buffer port 2 port 2 is a bidirectional port with internal pull-up resistors directly controlled via the p2 sfr. port 2 also emits the high order address bytes during fetches from external program memory and middle and high order address bytes during accesses to the 24-bit external data memory space. as shown in figure 40, the output drivers of ports 2 are switch- able to an internal addr bus by an internal control signal for use in external memory accesses (as for port 0). in external memory addressing mode (control = 1), the port pins feature push/pull operation controlled by the internal address bus (addr line). however unlike the p0 sfr during external memory accesses, the p2 sfr remains unchanged. in general-purpose i/o port mode, port 2 pins that have 1s written to them are pulled high by the internal pull-ups (figure 38) and, in that state, they can be used as inputs. as inputs, port 2 pins being pulled externally low will source current because of the internal pull-up resistors. port 2 pins with 0s written to them will drive a logic low output voltage (v ol ) and will be capable of sinking 1.6 ma. control read latch internal bus write to latch read pin d cl q q latch dv dd addr p2.x pin dv dd internal pull-up * * see figure 38 for details of internal pull-up figure 40. port 2 bit latch and i/o buffer port 3 port 3 is a bidirectional port with internal pull-ups directly controlled via the p3 sfr. port 3 pins that have 1s written to them are pulled high by the internal pull-ups and in that state they can be used as inputs. as inputs, port 3 pins being pulled externally low will source current because of the internal pull-ups. port 3 pins with 0s written to them will drive a logic low output voltage (v ol ) and will be capable of sinking 1.6 ma. port 3 pins also have various secondary functions described in table xxv. the alternate functions of port 3 pins can only be activated if the corresponding bit latch in the p3 sfr contains a 1. otherwise, the port pin is stuck at 0. table xxv. port 3, alternate pin functions pin alternate function p3.0 rxd (uart input pin) (or serial data i/o in mode 0) p3.1 txd (uart output pin) (or serial clock output in mode 0) p3.2 int0 (external interrupt 0) p3.3 int1 (external interrupt 1) p3.4 t0 (timer/counter 0 external input) pwmclk (pwm external clock) p3.5 t1 (timer/counter 1 external input) p3.6 wr (external data memory write strobe) p3.7 rd (external data memory read strobe) port 3 pins have the same bit latch and i/o buffer configurations as the p1.0 and p1.1 as shown in figure 41. the internal pull-up configuration is also defined by that in figure 38. read latch internal bus write to latch read pin d cl q q latch dv dd p3.x pin internal pull-up * * see figure 38 for details of internal pull-up alternate output function alternate input function figure 41. port 3 bit latch and i/o buffer additional digital i/o in addition to the port pins, the dedicated spi/i 2 c pins (sclock and sdata/mosi) also feature both input and output functions. their equivalent i/o architectures are illustrated in figure 42 and figure 44, respectively, for spi operation and in figure 43 and figure 45 for i 2 c operation. notice that in i 2 c mode (spe = 0), the strong pull-up fet (q1) is disabled leaving only a weak pull-up (q2) present. by contrast, in spi mode (spe = 1), the strong pull-up fet (q1) is controlled directly by spi hardware, giving the pin push/pull capability. in i 2 c mode (spe = 0), two pull-down fets (q3 and q4) operate in parallel in order to provide an extra 60% or 70% of current sinking capability. in spi mode, however, (spe = 1), only one of the pull-down fets (q3) operates on each pin resulting in sink capabilities identical to that of port 0 and port 2 pins. on the input path of sclock, notice that a schmitt trigger conditions the signal going to the spi hardware to prevent false triggers (double triggers) on slow incoming edges. for incoming signals from the sclock and sdata pins going to i 2 c hard- ware, a filter conditions the signals in order to reject glitches of up to 50 ns in duration.
rev. 0 aduc834 ?1 notice also that direct access to the sclock and sdata/mosi pins is afforded through the sfr interface in i 2 c master mode. therefore, if you are not using the spi or i 2 c functions, you can use these two pins to give additional high current digital outputs. hardware spi (master/slave) q3 schmitt trigger q1 q2 (off) dv dd sclock pin q4 (off) spe = 1 (spi enable) figure 42. sclock pin i/o functional equivalent in spi mode mco i2cm sfr bits 50ns glitch rejection filter hardware i 2 c (slave only) q3 q4 sclock pin q2 q1 (off) dv dd spe = 0 (i 2 c e nable) figure 43. sclock pin i/o functional equivalent in i 2 c mode hardware spi (master/slave) q3 q1 q2 (off) dv dd sdata/ mosi pin q4 (off) spe = 1 (spi enable) figure 44. sdata/mosi pin i/o functional equivalent in spi mode q3 q4 q2 q1 (off) dv dd mdi mdo mde i2cm hardware i 2 c (slave only) 50ns glitch rejection filter sdata/ mosi pin sfr bits spe = 0 (i 2 c e nable) figure 45. sdata/mosi pin i/o functional equivalent in i 2 c mode as shown in figure 46, the miso pin in spi master/slave operation offers the exact same pull-up and pull-down configu- ration as the mosi pin in spi slave/master operation. the ss pin has a weak internal pull-up permanently enabled to prevent the ss input from floating. this pull-up can be easily overdriven by an external device to drive the ss pin low. hardware spi (master/slave) miso pin dv dd figure 46. miso pin i/o functional equivalent hardware spi (master/slave) ss pin dv dd figure 47. ss pin i/o functional equivalent read-modify-write instructions some 8051 instructions that read a port read the latch and others read the pin. the instructions that read the latch rather than the pins are the ones that read a value, possibly change it, and then rewrite it to the latch. these are called ?ead-modify- write?instructions. listed below are the read-modify-write instructions. when the destination operand is a port, or a port bit, these instructions read the latch rather than the pin. anl (logical and, e.g., anl p1, a) orl (logical or, e.g., orl p2, a) xrl (logical ex-or, e.g., xrl p3, a) jbc (jump if bit = 1 and clear bit, e.g., jbc p1.1, label cpl (complement bit, e.g., cpl p3.0) inc (increment, e.g., inc p2) dec (decrement, e.g., dec p2) djnz (decrement and jump iff not zero, e.g.,djnz p3, label) mov px.y, c * (move carry to bit y of port x) clr px.y * (clear bit y of port x) setb px.y * (set bit y of port x) the reason that read-modify-write instructions are directed to the latch rather than the pin is to avoid a possible misinterpreta- tion of the voltage level of a pin. for example, a port pin might be used to drive the base of a transistor. when a 1 is written to the bit, the transistor is turned on. if the cpu then reads the same port bit at the pin rather then the latch, it will read the base voltage of the transistor and interpret it as a logic 0. read- ing the latch rather than the pin will return the correct value of 1. * these instruction read the port byte (all 8 bits), modify the addressed bit and then write the new byte back to the latch.
rev. 0 ?2 aduc834 timers/counters the aduc834 has three 16-bit timer/counters: timer 0, timer 1, and timer 2. the timer/counter hardware has been included on-chip to relieve the processor core of the overhead inherent in implementing timer/counter functionality in soft- ware. each timer/counter consists of two 8-bit registers thx and tlx (x = 0, 1 and 2). all three can be configured to oper- ate either as timers or event counters. in ?imer?function, the tlx register is incremented every machine cycle. thus it can be viewed as counting machine cycles. since a machine cycle consists of 12 core clock periods, the maximum count rate is 1/12 of the core clock frequency. in ?ounter?function, the tlx register is incremented by a 1-to-0 transition at its corresponding external input pin, t0, t1, or t2. in this function, the external input is sampled during s5p2 of every machine cycle. when the samples show a high in one cycle and a low in the next cycle, the count is incremented. the new count value appears in the register during s3p1 of the cycle following the one in which the transition was detected. since it takes two machine cycles (16 core clock periods) to recognize a 1-to-0 transition, the maximum count rate is 1/16 of the core clock frequency. there are no restrictions on the duty cycle of the external input signal, but to ensure that a given level is sampled at least once before it changes, it must be held for a minimum of one full machine cycle. remember that the core clock frequency is programmed via the cd0? selection bits in the pllcon sfr. user configuration and control of the timers is achieved via three main sfrs. tmod and tcon control the configuration of timers 0 and 1 while t2con configures timer 2. tmod timer/counter 0 and 1 mode register sfr address 89h power-on default value 00h bit addressable no table xxvi. tmod sfr bit designations bit name description 7 gate timer 1 gating control. set by software to enable timer/counter 1 only while int1 pin is high and tr1 control bit is set. cleared by software to enable timer 1 whenever tr1 control bit is set. 6c/ t timer 1 timer or counter select bit. set by software to select counter operation (input from t1 pin). cleared by software to select timer operation (input from internal system clock). 5m 1t imer 1 mode select bit 1 (used with m0 bit) 4m 0t imer 1 mode select bit 0. m1 m0 00 th1 operates as an 8-bit timer/counter. tl1 serves as 5-bit pre scaler. 01 16-bit timer/ counter. th1 and tl1 are cas caded; there is no prescaler. 10 8-bit auto-r eload timer/counter. th1 holds a value that is to be re loaded into tl1 each time it overflows. 11t imer/counter 1 stopped. 3 gate timer 0 gating control. set by software to enable timer/counter 0 only while int0 pin is high and tr0 control bit is set. cleared by software to enable timer 0 whenever tr0 control bit is set. 2c/ t timer 0 timer or counter select bit. set by software to select counter operation (input from t0 pin). cleared by software to select timer operation (input from internal system clock). 1m 1t imer 0 mode select bit 1 0m 0t imer 0 mode select bit 0. m1 m0 00 th0 operates as an 8-bit timer/counter. tl0 serves as 5-bit prescaler. 01 16-bit timer/counter. th0 and tl0 are cascaded; there is no prescaler 108 -bit auto-reload timer/counter. th0 holds a value that is to be re loaded into tl0 each time it overflows. 11 tl0 is an 8-bit timer/counter controlled by the standard timer 0 control bits. th0 is an 8-bit timer only, controlled by timer 1 control bits.
rev. 0 aduc834 ?3 tcon timer/counter 0 and 1 control register sfr address 88h power-on default value 00h bit addressable yes table xxvii. tcon sfr bit designations bit name description 7 tf1 timer 1 overflow flag. set by hardware on a timer/counter 1 overflow. cleared by hardware when the program counter (pc) vectors to the interrupt service routine. 6 tr1 timer 1 run control bit. set by user to turn on timer/counter 1. cleared by user to turn off timer/counter 1. 5 tf0 timer 0 overflow flag. set by hardware on a timer/counter 0 overflow. cleared by hardware when the pc vectors to the interrupt service routine. 4 tr0 timer 0 run control bit. set by user to turn on timer/counter 0. cleared by user to turn off timer/counter 0. 3 ie1 * external interrupt 1 ( int1 ) flag. set by hardware by a falling edge or zero level being applied to external interrupt pin int1 , depending on bit it1 state. cleared by hardware when the pc vectors to the interrupt service routine only if the interrupt was transition-activated. if level-activated, the external requesting source controls the request flag, rather than the on-chip hardware. 2 it1 * external interrupt 1 (ie1) trigger type. set by software to specify edge-sensitive detection (i.e., 1-to-0 transition). cleared by software to specify level-sensitive detection (i.e., zero level). 1 ie0 * external interrupt 0 ( int0 ) flag. set by hardware by a falling edge or zero level being applied to external interrupt pin int0 , depending on bit it0 state. cleared by hardware when the pc vectors to the interrupt service routine only if the interrupt was transition-activated. if level-activated, the exter nal requesting source con trols the re quest flag, rather than the on-chip hardware. 0 it0 * external interrupt 0 (ie0) trigger type. set by software to specify edge-sensitive detection (i.e., 1-to-0 transition). cleared by software to specify level-sensitive detection (i.e., zero level). * these bits are not used in the control of timer/counter 0 and 1, but are used instead in the control and monitoring of the exte rnal int0 and int1 interrupt pins. timer/counter 0 and 1 data registers both timer 0 and timer 1 consist of two 8-bit registers. these can be used as independent registers or combined to be a single 16-bit register, depending on the timer mode configuration. th0 and tl0 timer 0 high byte and low byte. sfr address = 8ch, 8ah, respectively. th1 and tl1 timer 1 high byte and low byte. sfr address = 8dh, 8bh, respectively.
rev. 0 ?4 aduc834 timer/counter 0 and 1 operating modes the following paragraphs describe the operating modes for timer/counters 0 and 1. unless otherwise noted, it should be assumed that these modes of operation are the same for timer 0 as for timer 1. mode 0 (13-bit timer/counter) mode 0 configures an 8-bit timer/counter with a divide-by-32 prescaler. figure 48 shows mode 0 operation. 12 core clk * control p3.4/t0 gate p3.2/ int0 tr0 tf0 tl0 (5 bits) th0 (8 bits) interrupt c/ t = 0 c/ t = 1 * the core clock is the output of the pll (see "on-chip pll") figure 48. timer/counter 0, mode 0 in this mode, the timer register is configured as a 13-bit register. as the count rolls over from all 1s to all 0s, it sets the timer over- flow flag. the overflow flag, tf0, can then be used to request an interrupt. the counted input is enabled to the timer when tr0 = 1 and either gate = 0 or int0 = 1. setting gate = 1 allows the timer to be controlled by external input int0 , to facilitate pulsewidth measurements. tr0 is a control bit in the special function register tcon; gate is in tmod. the 13-bit register consists of all eight bits of th0 and the lower five bits of tl0. the upper three bits of tl0 are indeterminate and should be ignored. setting the run flag (tr0) does not clear the registers. mode 1 (16-bit timer/counter) mode 1 is the same as mode 0, except that the timer register is running with all 16 bits. mode 1 is shown in figure 49. 12 core clk * control p3.4/t0 gate p3.2/ int0 tr0 tf0 tl0 (8 bits) th0 (8 bits) interrupt c/ t = 0 c/ t = 1 * the core clock is the output of the pll (see "on-chip pll") figure 49. timer/counter 0, mode 1 mode 2 (8-bit timer/counter with auto reload) mode 2 configures the timer register as an 8-bit counter (tl0) with automatic reload, as shown in figure 50. overflow from tl0 not only sets tf0, but also reloads tl0 with the contents of th0, which are preset by software. the reload leaves th0 unchanged. control tf0 tl0 (8 bits) interrupt reload th0 (8 bits) 12 core clk * p3.4/t0 gate p3.2/ int0 tr0 c/ t = 0 c/ t = 1 * the core clock is the output of the pll (see "on-chip pll") figure 50. timer/counter 0, mode 2 mode 3 (two 8-bit timer/counters) mode 3 has different effects on timer 0 and timer 1. timer 1 in mode 3 simply holds its count. the effect is the same as setting tr1 = 0. timer 0 in mode 3 establishes tl0 and th0 as two separate counters. this configuration is shown in figure 51. tl0 uses the timer 0 control bits: c/ t , gate, tr0, int0 , and tf0. th0 is locked into a timer function (counting machine cycles) and takes over the use of tr1 and tf1 from timer 1. thus, th0 now controls the ?imer 1?interrupt. mode 3 is provided for applications requiring an extra 8-bit timer or counter. when timer 0 is in mode 3, timer 1 can be turned on and off by switching it out of and into its own mode 3, or can still be used by the serial interface as a baud rate generator. in fact, it can be used, in any application not requiring an interrupt from timer 1 itself. control tf0 tl0 (8 bits) interrupt 12 core clk * p3.4/t0 gate p3.2/ int0 tr0 c/ t = 0 c/ t = 1 * the core clock is the output of the pll (see "on-chip pll") core clk/12 tf1 th0 (8 bits) interrupt core clk/12 tr1 figure 51. timer/counter 0, mode 3
rev. 0 aduc834 ?5 timer/counter 2 operating modes the following paragraphs describe the operating modes for timer/counter 2. the operating modes are selected by bits in the t2con sfr as shown in table xxix. table xxviii. timer 2 operating modes rclk (or) tclk cap2 tr2 mode 00 1 16-bit autoreload 01 1 16-bit capture 1x 1b aud rate xx0 off 16-bit autoreload mode in autoreload mode, there are two options, selected by bit exen2 in t2con. if exen2 = 0, when timer 2 rolls over it not only sets tf2 but also causes the timer 2 registers to be reloaded with the 16-bit value in registers rcap2l and rcap2h, which are preset by software. if exen2 = 1, timer 2 still performs the above, but with the added feature that a 1-to-0 transition at external input t2ex will also trigger the 16-bit reload and set exf2. the autoreload mode is illustrated in figure 52. 16-bit capture mode in the capture mode, there are again two options, selected by bit exen2 in t2con. if exen2 = 0, timer 2 is a 16-bit timer or counter that, upon overflowing, sets bit tf2, the timer 2 over- flow bit, which can be used to generate an interrupt. if exen2 = 1, timer 2 still performs the above, but a l-to-0 transition on ex ternal input t2ex causes the current value in the timer 2 registers, tl2 and th2, to be captured into registers rcap2l and rcap2h, respectively. in addition, the transition at t2ex causes bit exf2 in t2con to be set; exf2, like tf2, can gener- ate an interrupt. the capture mode is illustrated in figure 53. the baud rate generator mode is selected by rclk = 1 and/or tclk = 1. in either case, if timer 2 is being used to generate the baud rate, the tf2 interrupt flag will not occur. therefore timer 2 interrupts will not occur so they do not have to be disabled. however, in this mode, the exf2 flag can still cause interrupts and this can be used as a third external interrupt. baud rate generation will be described as part of the uart serial port operation. core clk * 12 t2 pin c/ t2 = 0 c/ t2 = 1 tr2 control tl2 (8 bits) th2 (8 bits) reload tf2 exf2 timer interrupt exen2 control transition detector t2ex pin rcap2l rcap2h * the core clock is the output of the pll (see "on-chip pll") figure 52. timer/counter 2, 16-bit autoreload mode tf2 core clk * 12 t2 pin tr2 control tl2 (8 bits) th2 (8 bits) capture exf2 timer interrupt exen2 control transition detector t2ex pin rcap2l rcap2h c/ t2 = 0 c/ t2 = 1 * the core clock is the output of the pll (see "on-chip pll") figure 53. timer/counter 2, 16-bit capture mode
rev. 0 ?6 aduc834 t2con timer/counter 2 control register sfr address c8h power-on default value 00h bit addressable yes table xxix. t2con sfr bit designations bit name description 7 tf2 timer 2 overflow flag. set by hardware on a timer 2 overflow. tf2 will not be set when either rclk or tclk = 1. cleared by user software. 6 exf2 timer 2 external flag. set by hardware when either a capture or reload is caused by a negative transition on t2ex and exen2 = 1. cleared by user software. 5 rclk receive clock enable bit. set by user to enable the serial port to use timer 2 overflow pulses for its receive clock in serial port modes 1 and 3. cleared by user to enable timer 1 overflow to be used for the receive clock. 4 tclk transmit clock enable bit. set by user to enable the serial port to use timer 2 overflow pulses for its transmit clock in serial port modes 1 and 3. cleared by user to enable timer 1 overflow to be used for the transmit clock. 3 exen2 timer 2 external enable flag. set by user to enable a capture or reload to occur as a result of a negative transition on t2ex if timer 2 is not being used to clock the serial port. cleared by user for timer 2 to ignore events at t2ex. 2 tr2 timer 2 start/stop control bit. set by user to start timer 2. cleared by user to stop timer 2. 1 cnt2 timer 2 timer or counter function select bit. set by user to select counter function (input from external t2 pin). cleared by user to select timer function (input from on-chip core clock). 0 cap2 timer 2 capture/reload select bit. set by user to enable captures on negative transitions at t2ex if exen2 = 1. cleared by user to enable auto reloads with timer 2 overflows or negative transitions at t2ex when exen2 = 1. when either rclk = 1 or tclk = 1, this bit is ignored and the timer is forced to autoreload on timer 2 overflow. timer/counter 2 data registers timer/counter 2 also has two pairs of 8-bit data registers associated with it. these are used as both timer data registers and timer capture/reload registers. th2 and tl2 timer 2, data high byte and low byte. sfr address = cdh, cch, respectively. rcap2h and rcap2l timer 2, capture/reload byte and low byte. sfr address = cbh, cah, respectively.
rev. 0 aduc834 ?7 uart serial interface the serial port is full duplex, meaning it can transmit and receive simultaneously. it is also receive-buffered, meaning it can commence reception of a second byte before a previously received byte has been read from the receive register. however, if the first byte still has not been read by the time reception of the second byte is complete, the first byte will be lost. the physical interface to the serial data network is via pins rxd(p3.0) and txd(p3.1), while the sfr interface to the uart comprises the following registers: sbuf the serial port receive and transmit registers are both accessed through the sbuf sfr (sfr address = 99h). writing to sbuf loads the transmit register and reading sbuf accesses a physically separate receive register. scon uart serial port control registers sfr address 98h power-on default value 00h bit addressable yes table xxx. scon sfr bit designations bit name description 7 sm0 uart serial mode select bits. 6 sm1 these bits select the serial port operating mode as follows: sm0 sm1 selected operating mode 00 mode 0: shift register, fixed baud rate (f core /12) 01 mode 1: 8-bit uart, variable baud rate 10 mode 2: 9-bit uart, fixed baud rate (f core /64) or (f core / 32) 11 mode 3: 9-bit uart, variable baud rate 5 sm2 multiprocessor communication enable bit. enables multiprocessor communication in modes 2 and 3. in mode 0, sm2 should be cleared. in mode 1, if sm2 is set, ri will not be activated if a valid stop bit was not received. if sm2 is cleared, ri will be set as soon as the byte of data has been received. in modes 2 or 3, if sm2 is set, ri will not be activated if the received ninth data bit in rb8 is 0. if sm2 is cleared, ri will be set as soon as the byte of data has been received. 4 ren serial port receive enable bit. set by user software to enable serial port reception. cleared by user software to disable serial port reception. 3t b8 serial port transmit (bit 9). the data loaded into tb8 will be the ninth data bit that will be transmitted in modes 2 and 3. 2 rb8 serial port receiver bit 9. the ninth data bit received in modes 2 and 3 is latched into rb8. for mode 1, the stop bit is latched into rb8. 1t i serial port transmit interrupt flag. set by hardware at the end of the eighth bit in mode 0, or at the beginning of the stop bit in modes 1, 2, and 3. ti must be cleared by user software. 0r i serial port receive interrupt flag. set by h ardware at the end of the eighth bit in mode 0, or halfway through the stop bit in modes 1, 2, and 3. ri must be cleared by software. uart operating modes mode 0: 8-bit shift register mode mode 0 is selected by clearing both the sm0 and sm1 bits in the sfr scon. serial data enters and exits through rxd. txd outputs the shift clock. eight data bits are transmitted or received. trans- mission is initiated by any instruction that writes to sbuf. the data is shifted out of the rxd line. the 8 bits are transmitted with the least-significant bit (lsb) first, as shown in figure 54. reception is initiated when the receive enable bit (ren) is 1 and the receive interrupt bit (ri) is 0. when ri is cleared, the data is clocked into the rxd line and the clock pulses are output from the txd line. core clk ale rxd (data out) txd (shift clock) data bit 0 data bit 1 data bit 6 data bit 7 s6 s5 s4 s3 s2 s1 s6 s5 s4 s4 s3 s2 s1 s6 s5 s4 s3 s2 s1 machine cycle 8 machine cycle 7 machine cycle 2 machine cycle 1 figure 54. uart serial port transmission, mode 0
rev. 0 ?8 aduc834 mode 1: 8-bit uart, variable baud rate mode 1 is selected by clearing sm0 and setting sm1. each data byte (lsb first) is preceded by a start bit (0) and followed by a stop bit (1). therefore 10 bits are transmitted on txd or received on rxd. the baud rate can be set by timer 1 or timer 2 (or both). alternatively, a dedicated baud rate generator, timer 3, is provided on-chip to generate high speed, very accurate baud rates. transmission is initiated by writing to sbuf. the ?rite to sbuf?signal also loads a 1 (stop bit) into the ninth bit position of the transmit shift register. the data is output bit by bit until the stop bit appears on txd and the transmit interrupt flag (ti) is automatically set as shown in figure 55. txd ti (sco n.1) start bit d0 d1 d2 d3 d4 d5 d6 d7 stop bit set interrupt i.e., ready for more data figure 55. uart serial port transmission, mode 0 reception is initiated when a 1-to-0 transition is detected on rxd. assuming a valid start bit was detected, character recep- tion continues. the start bit is skipped and the eight data bits are clocked into the serial port shift register. when all eight bits have been clocked in, the following events occur: the eight bits in the receive shift register are latched into sbuf the ninth bit (stop bit) is clocked into rb8 in scon the receiver interrupt flag (ri) is set if, and only if, the following conditions are met at the time the final shift pulse is generated: ri = 0, and either sm2 = 0, or sm2 = 1 and the received stop bit = 1. if either of these conditions is not met, the received frame is irretrievably lost and ri is not set. mode 2: 9-bit uart with fixed baud rate mode 2 is selected by setting sm0 and clearing sm1. in this mode, the uart operates in 9-bit mode with a fixed baud rate. the baud rate is fixed at core_clk/64 by default, although by setting the smod bit in pcon, the frequency can be doubled to core_clk/32. eleven bits are transmitted or received, a start bit (0), eight data bits, a programmable ninth bit, and a stop bit (1). the ninth bit is most often used as a parity bit, although it can be used for anything, including a ninth data bit if required. to transmit, the eight data bits must be written into sbuf. the ninth bit must be written to tb8 in scon. when transmission is initiated, the eight data bits (from sbuf) are loaded onto the transmit shift register (lsb first). the contents of tb8 are loaded into the ninth bit position of the transmit shift register. the transmission will start at the next valid baud rate clock. the ti flag is set as soon as the stop bit appears on txd. reception for mode 2 is similar to that of mode 1. the eight data bytes are input at rxd (lsb first) and loaded onto the receive shift register. when all eight bits have been clocked in, the following events occur: the eight bits in the receive shift register are latched into sbuf the ninth data bit is latched into rb8 in scon the receiver interrupt flag (ri) is set if, and only if, the following conditions are met at the time the final shift pulse is generated: ri = 0, and either sm2 = 0, or sm2 = 1 and the received stop bit = 1. if either of these conditions is not met, the received frame is irretrievably lost and ri is not set. mode 3: 9-bit uart with variable baud rate mode 3 is selected by setting both sm0 and sm1. in this mode, the 8051 uart serial port operates in 9-bit mode with a variable baud rate determined by either timer 1 or timer 2. the opera- tion of the 9-bit uart is the same as for mode 2, but the baud rate can be varied as for mode 1. in all four modes, transmission is initiated by any instruction that uses sbuf as a destination register. reception is initiated in mode 0 by the condition ri = 0 and ren = 1. reception is initiated in the other modes by the incoming start bit if ren = 1. uart serial port baud rate generation mode 0 baud rate generation the baud rate in mode 0 is fixed: mode 0 baud rate f core = * 12 mode 2 baud rate generation the baud rate in mode 2 depends on the value of the smod b it in the pcon sfr. if smod = 0, the baud rate is 1/64 of the core clock. if smod = 1, the baud rate is 1/32 of the core clock: mode 2 baud rate f core smod = * 2 64 mode 1 and 3 baud rate generation traditionally, the baud rates in modes 1 and 3 are determined by the overflow rate in timer 1 or timer 2, or both (one for transmit and the other for receive). on the aduc834, however, the baud rate can also be generated via a separate baud rate generator to achieve higher baud rates and allow all three to be used for other functions. * f core refers to the output of the pll as described in the ?n-chip pll?section.
rev. 0 aduc834 ?9 core clk * 2 t2 pin tr2 control tl2 (8 bits) th2 (8 bits) reload exen2 control t2ex pin transition detector exf 2 timer 2 interrupt note availability of additional external interrupt * the core clock is the output of the pll (see "on-chip pll") rcap2l rcap2h timer 2 overflow 2 16 16 rclk tclk rx clock tx clock 0 0 1 1 1 0 smod timer 1 overflow c/ t2 = 0 c/ t2 = 1 osc. freq. is divided by 2, not 12. figure 56. timer 2, uart baud rates baud rate generation using timer 1 and timer 2 timer 1 generated baud rates when timer 1 is used as the baud rate generator, the baud rates in modes 1 and 3 are determined by the timer 1 overflow rate and the value of smod as follows: modes 1 3 1 and baud rate timer overflow rate smod = () () 232 the timer 1 interrupt should be disabled in this application. the timer itself can be configured for either timer or counter operation, and in any of its three running modes. in the most typical application, it is configured for timer operation, in the autoreload mode (high nibble of tmod = 0100 binary). in that case, the baud rate is given by the formula: mode 1 3 1 and mode baud rate f th smod core = - () 2 32 12 256 a very low baud rate can also be achieved with timer 1 by leaving the timer 1 interrupt enabled, configuring the timer to run as a 16-bit timer (high nibble of tmod = 0100 binary), and using the timer 1 interrupt to do a 16-bit software reload. table xxxi shows some commonly-used baud rates and how they might be calculated from a core clock frequency of 1.5728 mhz and 12.58 mhz using timer 1. generally speaking, a 5% error is tolerable using asynchronous (start/stop) communications. table xxxi. commonly used baud rates, timer 1 ideal core smod th1-reload actual % baud clk value value baud error 9600 12.58 1 C 7 (f9h) 9362 2.5 1600 12.58 1 C 27 (e5h) 1627 1.1 1200 12.58 1 C 55 (c9h) 1192 0.7 1200 1.57 1 C 7 (f9h) 1170 2.5 timer 2 generated baud rates baud rates can also be generated using timer 2. using timer 2 is similar to using timer 1 in that the timer must overflow 16 times before a bit is transmitted/received. because timer 2 has a 16-bit autoreload mode, a wider range of baud rates is pos- sible using timer 2. mode 1 3 and mode baud rate timer overflow rate = () () 116 2 therefore when timer 2 is used to generate baud rates, the timer increments every two clock cycles and not every core machine cycle as before. thus, it increments six times faster than timer 1, and therefore baud rates six times faster are pos- sible. because timer 2 has a 16-bit autoreload capability, very low baud rates are still possible. timer 2 is selected as the baud rate generator by setting the tclk and/or rclk in t2con. the baud rates for transmit and receive can be simultaneously different. setting rclk and/or tclk puts timer 2 into its baud rate generator mode as shown in figure 56. in this case, the baud rate is given by the formula: mode 1 3 and mode baud rate f rcap h l core = - () 32 65536 2 table xxxii shows some commonly used baud rates and how they might be calculated from a core clock frequency of 1.5728 mhz and 12.5829 mhz using timer 2. table xxxii. commonly used baud rates, timer 2 ideal core rcap2h rcap2l actual % baud clk value value baud error 19200 12.58 C 1 (ffh) C 20 (ech) 19661 2.4 9600 12.58 C 1 (ffh) C 41 (d7h) 9591 0.1 1600 12.58 C 1 (ffh) C 164 (5ch) 2398 0.1 1200 12.58 C 2 (feh) C 72 (b8h) 1199 0.1 9600 1.57 C 1 (ffh) C 5 (fbh) 9830 2.4 1600 1.57 C 1 (ffh) C 20 (ech) 1658 2.4 1200 1.57 C 1 (ffh) C 41 (d7h) 1199 0.1
rev. 0 ?0 aduc834 baud rate generation using timer 3 the high integer dividers in a uart block means that high speed baud rates are not always possible using some particular crystals. e.g., using a 12 mhz crystal, a baud rate of 115200 is not possible. to address this problem the aduc834 has added a dedicated baud rate timer (timer 3) specifically for generating highly accurate baud rates. timer 3 can be used instead of timer 1 or timer 2 for generating very accurate high speed uart baud rates including 115200 and 230400. timer 3 also allows a much wider range of baud rates to be obtained. in fact, every desired bit rate from 12 bits to 393216 bits can be generated to within an error of 0.8%. timer 3 also frees up the other three timers allowing them to be used for different applications. a block diagram of timer 3 is shown in figure 57. (1 + t3fd/64) 2 t3 rx/tx clock core clk * t3en rx clock tx clock timer 1/timer 2 rx clock (fig 56) fractional divider 0 0 1 1 timer 1/timer 2 tx clock (fig 56) 16 2 div * the core clock is the output of the pll (see "on-chip pll") figure 57. timer 3, uart baud rates two sfrs (t3con and t3fd) are used to control timer 3. t3con is the baud rate control sfr, allowing timer 3 to be used to set up the uart baud rate, and setting up the binary divider (div). table xxxiii. t3con sfr bit designations bit name description 7 t3en set to enable timer 3 to generate the baud rate. when set pcon.7, t2con.4 and t2con.5 are ignored. cleared to let the baud rate be generated as per a standard 8052. 6 reserved for future use 5 reserved for future use 4 reserved for future use 3 reserved for future use 2 div2 binary divider factor 1 div1 div2 div1 div0 bin divider 0 div0 0 0 0 1 0012 0104 0118 10016 10132 11064 111 128 the appropriate value to write to the div2-1-0 bits can be calculated using the following formula where f core is the output of the pll as described in the ?n-chip pll?description. note: the div value must be rounded down. div f baud rate core = ? ? ? () log log 32 2 t 3 fd is the fractional divider ratio required to achieve the required baud rate. we can calculate the appropriate value for t 3 fd using the following formula. note: t 3 fd should be rounded to the nearest integer. tfd f baud rate core div 3 2 2 64 = - once the values for div and t 3 fd are calculated, the actual baud rate can be calculated using the following formula: actual baud rate f tfd core div = + () 2 2364 for a baud rate of 115200 while operating from the maximum core frequency (cd = 0) we have: div tfd dh = () == = () () -= = log / / log . .. 12582912 32 115200 2 1 77 1 32 12 582912 2 115200 64 45 22 2 1 therefore, the actual baud rate is 115439 bits. table xxxiv. commonly used baud rates using timer 3 ideal % baud cd div t3con t3fd error 230400 0 0 80h 2dh 0.2 115200 0 1 81h 2dh 0.2 115200 1 0 80h 2dh 0.2 57600 0 2 82h 2dh 0.2 57600 1 1 81h 2dh 0.2 57600 2 0 80h 2dh 0.2 38400 0 3 83h 12h 0.1 38400 1 2 82h 12h 0.1 38400 2 1 81h 12h 0.1 38400 3 0 80h 12h 0.1 19200 0 4 84h 12h 0.1 19200 1 3 83h 12h 0.1 19200 2 2 82h 12h 0.1 19200 3 1 81h 12h 0.1 19200 4 0 80h 12h 0.1 9600 0 5 85h 12h 0.1 9600 1 4 84h 12h 0.1 9600 2 3 83h 12h 0.1 9600 3 2 82h 12h 0.1 9600 4 1 81h 12h 0.1 9600 5 0 80h 12h 0.1 38400 0 3 83h 12h 0.1
rev. 0 aduc834 ?1 interrupt system the aduc834 provides a total of 11 interrupt sources with two priority levels. the control and configuration of the interrupt s ystem is carried out through three interrupt-related sfrs. these are the ie (interrupt enable) register, the ip (interrupt priority r egister) and the ieip2 (secondary interrupt enable/priority sfr) registers. their bit definitions are given in the tables xxxv xxxvii. ie interrupt enable register sfr address a8h power-on default value 00h bit addressable yes table xxxv. ie sfr bit designations bit name description 7e aw ritten by user to enable ??or disable ??all interrupt sources 6 eadc written by user to enable ??or disable ??adc interrupt 5 et2 written by user to enable ??or disable ??timer 2 interrupt 4e sw ritten by user to enable ??or disable ??uart serial port interrupt 3 et1 written by user to enable ??or disable ??timer 1 interrupt 2 ex1 written by user to enable ??or disable ??external interrupt 1 1 et0 written by user to enable ??or disable ??timer 0 interrupt 0 ex0 written by user to enable ??or disable ??external interrupt 0 ip interrupt priority register sfr address b8h power-on default value 00h bit addressable yes table xxxvi. ip sfr bit designations bit name description 7 reserved for future use 6 padc written by user to select adc interrupt priority (??= high; ??= low) 5 pt2 written by user to select timer 2 interrupt priority (??= high; ??= low) 4p sw ritten by user to select uart serial port interrupt priority (??= high; ??= low) 3 pt1 written by user to select timer 1 interrupt priority (??= high; ??= low) 2 px1 written by user to select external interrupt 1 priority (??= high; ??= low) 1 pt0 written by user to select timer 0 interrupt priority (??= high; ??= low) 0 px0 written by user to select external interrupt 0 priority (??= high; ??= low) ieip2 secondary interrupt enable and priority register sfr address a9h power-on default value a0h bit addressable no table xxxvii. ieip2 sfr bit designations bit name description 7 reserved for future use 6p ti written by user to select tic interrupt priority (??= high; ??= low) 5 ppsm written by user to select power supply monitor interrupt priority (??= high; ??= low) 4p si written by user to select spi/i 2 c serial port interrupt priority (??= high; ??= low) 3 reserved. this bit must be ?. 2 eti written by user to enable ??or disable ??tic interrupt 1e psm written by user to enable ??or disable ??power supply monitor interrupt 0 esi written by user to enable ??or disable ??spi/i 2 c serial port interrupt
rev. 0 ?2 aduc834 interrupt priority the interrupt enable registers are written by the user to enable individual interrupt sources, while the interrupt priority registers allow the user to select one of two priority levels for each inter- rupt. an interrupt of a high priority may interrupt the service routine of a low priority interrupt, and if two interrupts of different priority occur at the same time, the higher level interrupt will be serviced first. an interrupt cannot be interrupted by another interrupt of the same priority level. if two interrupts of the same priority level occur simultaneously, a polling sequence is used to determine which interrupt is serviced first. the polling sequence is shown in table xxxviii. table xxxviii. priority within an interrupt level source priority description psmi 1 (highest) power supply monitor inter rupt wds 2 watchdog interrupt ie0 3 external interrupt 0 rdy0/rdy1 4 adc interrupt tf0 5 timer/counter 0 interrupt ie1 6 external interrupt 1 tf1 7 timer/counter 1 interrupt ispi/i2ci 8 spi interrupt ri + ti 9 serial interrupt tf2 + exf2 10 timer/counter 2 interrupt tii 11 (lowest) time interval counter inter rupt interrupt vectors when an interrupt occurs, the program counter is pushed onto the stack and the corresponding interrupt vector address is loaded into the program counter. the interrupt vector addresses are shown in table xxxix. table xxxix. interrupt vector addresses source vector address ie0 0003h tf0 000bh ie1 0013h tf1 001bh ri + ti 0023h tf2 + exf2 002bh rdy0/rdy1 (adc) 0033h ispi/i2ci 003bh psmi 0043h tii 0053h wds (wdir = 1) * 005bh * the watchdog can be configured to generate an interrupt instead of a reset when it times out. this is used for logging errors or to examine the internal status of the microcontroller core to understand, from a software debug point of view, why a watchdog timeout occurred. the watchdog interrupt is slightly different from the normal interrupts in that its priority level is always set to 1 and it is not possible to disable the interrupt via the global disable bit ( ea ) in the ie sfr. this is done to ensure that the interrupt will always be responded to if a watchdog timeout occurs. the watchdog will only produce an interrupt if the watchdog timeout is greater than zero.
rev. 0 aduc834 ?3 aduc834 hardware design considerations this section outlines some of the key hardware design consider- ations that must be addressed when integrating the aduc834 into any hardware system. external memory interface in addition to its internal program and data memories, the aduc834 can access up to 64 kbytes of external program memory (rom/prom/and so on) and up to 16 mbytes of external data memory (sram). to select from which code space (internal or external program memory) to begin executing code, tie the ea (external access) pin high or low, respectively. when ea is high (pulled up to v dd ), user program execution will start at address 0 in the internal 62 kbytes flash/ee code space. when ea is low (tied to ground) user program execution will start at address 0 in the external code space. when executing from internal code space, accesses to the program space above f7ffh (62 kbytes) will be read as nop instructions. note that a second very important function of the ea pin is described in the single pin emulation mode section. external program memory (if used) must be connected to th e aduc834 as illustrated in figure 58. sixteen i/o lines (ports 0 and 2) are dedicated to bus functions during external program memory fetches. port 0 (p0) serves as a multiplexed address/databus. it emits the low byte of the program counter (pcl) as an address, and then goes into a high impedance input state awaiting the arrival of the code byte from the program memory. during the time that the low byte of the program counter is valid on p0, the signal ale (address latch enable) clocks this byte into an external address latch. meanwhile, port 2 (p2) emits the high byte of the program counter (pch), and psen strobes the eprom and the code byte is read into the aduc834. latch eprom oe a8?15 a0?7 d0?7 (instruction) aduc834 psen p2 ale p0 figure 58. external program memory interface note that program memory addresses are always 16 bits wide, even in cases where the actual amount of program memory used is less than 64 kbytes. external program execution sacrifices two of the 8-bit ports (p0 and p2) to the function of addressing the program memory. while executing from external program memory, ports 0 and 2 can be used simultaneously for read/write access to external data memory, but not for general-purpose i/o. though both external program memory and external data memory are accessed using some of the same pins, the two are completely independent of each other from a software point of view. for example, the chip can read/write external data memory while executing from external program memory. figure 59 shows a hardware configuration for accessing up to 64 kbytes of external data memory. this interface is standard to any 8051 compatible mcu. latch sram oe a8?15 a0?7 d0?7 (data) aduc834 rd p2 ale p0 we wr figure 59. external data memory interface (64 kbytes address space) if access to more than 64 kbytes of ram is desired, a feature unique to the microconverter allows addressing up to 16 mbytes of external ram simply by adding an additional latch as illus- trated in figure 60. latch aduc834 rd p2 ale p0 wr latch sram oe a8?15 a0?7 d0?7 (data) we a16?23 figure 60. external data memory interface (16 mbytes address space) in either implementation, port 0 (p0) serves as a multiplexed address/databus. it emits the low byte of the data pointer (dpl) as an address, which is latched by ale prior to data being placed on the bus by the aduc834 (write operation) or the external data memory (read operation). port 2 (p2) provides the data pointer page byte (dpp) to be latched by ale, followed by the data pointer high byte (dph). if no latch is connected to p2, dpp is ignored by the sram, and the 8051 standard of 64 kbyte external data memory access is maintained. detailed timing diagrams of external program and data memory read and write access can be found in the timing specification sections of this data sheet.
rev. 0 ?4 aduc834 power supplies the aduc834? operational power supply voltage range is 2.7 v to 5.25 v. although the guaranteed data sheet specifica- tions are given only for power supplies within 2.7 v to 3.6 v or 5% of the nominal 5 v level, the chip will function equally well at any power supply level between 2.7 v and 5.25 v. separate analog and digital power supply pins (av dd and dv dd respectively) allow av dd to be kept relatively free of noisy digi- tal signals often present on the system dv dd line. in this mode, the part can also operate with split supplies; that is, using differ- ent voltage supply levels for each supply. for example, this means that the system can be designed to operate with a dv dd voltage level of 3 v while the av dd level can be at 5 v, or vice- versa if required. a typical split supply configuration is shown in figure 61. dv dd 48 34 20 aduc834 5 6 agnd av dd + 0.1 f 10 f analog supply 10 f dgnd 35 21 47 0.1 f digital supply + figure 61. external dual supply connections as an alternative to providing two separate power supplies, av dd can be kept quiet by placing a small series resistor and/or ferrite bead between it and dv dd , and then decoupling av dd separately to ground. an example of this configuration is shown in figure 62. in this configuration, other analog circuitry (such as op amps, voltage reference, and so on) can be powered from the av dd supply line as well. dv dd 48 34 20 aduc834 5 6 agnd av dd 0.1 f 10 f dgnd 35 21 47 0.1 f + digital supply 10 f 1.6 bead figure 62. external single supply connections notice that in both figure 61 and figure 62 a large value (10 f) reservoir capacitor sits on dv dd and a separate 10 f capacitor sits on av dd . also, local decoupling capacitors (0.1 f) are lo cated at each v dd pin of the chip. as per standard design practice, be sure to include all of these capacitors and ensure the smaller capacitors are closest to each v dd pin with lead lengths as short as possible. connect the ground terminal of each of these capacitors directly to the underlying ground plane. finally, it should also be noticed that, at all times, the analog and digital ground pins on the aduc834 should be referenced to the same system ground reference point. power-on reset operation an internal por (power-on reset) is implemented on the aduc834. for dv dd below 2.45 v, the internal por will hold the aduc834 in reset. as dv dd rises above 2.45 v, an internal timer will time out for typically 128 ms before the part is released from reset. the user must ensure that the power supply has reached a stable 2.7 v minimum level by this time. likewise on power-down, the internal por will hold the aduc834 in reset until the power supply has dropped below 1 v. figure 63 illustrates the operation of the internal por in detail. 128ms typ 1.0v typ 128ms typ 2.45v typ 1.0v typ internal core reset dv dd figure 63. internal power-on-reset operation power consumption the dv dd power supply current consumption is specified in normal, idle, and power-down modes. the av dd power supply current is specified with the analog peripherals disabled. the normal mode power consumption represents the current drawn from dv dd by the digital core. the other on-chip peripherals (watchdog timer, power supply monitor, and so on) consume negli gible current and are therefore lumped in with the normal operating current here. of course, the user must add any cur- rents sourced by the parallel and serial i/o pins, and those sourced by the dac in order to determine the total current needed at the aduc834? dv dd and av dd supply pins. also, current drawn from the dv dd supply will increase by approxi- mately 5 ma during flash/ee erase and program cycles.
rev. 0 aduc834 ?5 power saving modes setting the idle and power-down mode bits, pcon.0 and pcon.1 respectively, in the pcon sfr described in table ii allows the chip to be switched from normal mode into idle mode, and also into full power-down mode. in idle mode, the oscillator continues to run, but the core clock generated from the pll is halted. the on-chip peripherals continue to receive the clock and remain functional. the cpu status is preserved with the stack pointer, program counter, and all other internal registers maintain their data during idle mode. port pins and dac output pins also retain their states, and ale and psen outputs go high in this mode. the chip will recover from idle mode upon receiving any enabled interrupt, or on receiving a hardware reset. in power-down mode, both the pll and the clock to the core are stopped. the on-chip oscillator can be halted or can continue to oscillate, depending on the state of the oscillator pow er-down bit (osc_pd) in the pllcon sfr. the tic, being driven directly from the oscillator, can also be enabled during power- down. all other on-chip peripherals however, are shut down. port pins retain their logic levels in this mode, but the dac output goes to a high impedance state (three-state) while ale and psen outputs are held low. during full power-down mode with the oscillator and wake-up timer running, the aduc834 typically consumes a total of 15 a. there are five ways of terminating power-down mode: asserting the reset pin (pin 15) returns to normal mode. all registers are set to their reset default value and program execution starts at the reset vector once the reset pin is deasserted. cycling power all registers are set to their default state and program execution starts at the reset vector approximately 128 ms later. time interval counter (tic) interrupt if the osc_pd bit in the pllcon sfr is clear, the 32 khz oscillator will remain powered up even in power-down mode. if the time interval counter (wakeup/rtc timer) is enabled, at ic interrupt will wake the aduc834 up from power-down mode. the cpu services the tic interrupt. the reti at the end of the tic isr will return the core to the instruction after that which enabled power-down. spi interrupt if the seripd bit in the pcon sfr is set, then an spi inter- rupt, if enabled, will wake the aduc834 up from power-down mode. the cpu services the spi interrupt. the reti at the end of the isr will return the core to the instruction after that which enabled power-down. int0 interrupt if the int0pd bit in the pcon sfr is set, an external interrupt 0, if enabled, will wake up the aduc834 from power- down. the cpu services the spi interrupt. the reti at the end of the isr will return the core to the instruction after that which enabled power-down. wake-up from power-down latency even with the 32 khz crystal enabled during power-down, the pll will take some time to lock after a wake-up from power- down. typically, the pll will take about 1 ms to lock. during this time, code will execute but not at the specified frequency. some operations require an accurate clock, for example uart communications, to achieve specified 50/60 hz rejection from the adcs. the following code may be used to wait for the pll to lock: waitforlock: mov a, pllcon jnb acc.6, waitforlock if the crystal has been powered down during power-down, there is an additional delay associated with the startup of the crystal oscillator before the pll can lock. 32 khz crystals are inherently slow to oscillate, typically taking about 150 ms. once again, during this time before lock, code will execute but the exact frequency of the clock cannot be guaranteed. again for any timing sensitive operations, it is recommended to wait for lock using the lock bit in pllcon as shown above. grounding and board layout recommendations as with all high resolution data converters, special attention must be paid to grounding and pc board layout of aduc834-based designs in order to achieve optimum performance from the adcs and dac. although the aduc834 has separate pins for analog and digital ground (agnd and dgnd), the user must not tie these to two separate ground planes unless the two ground planes are con- nected together very close to the aduc834, as illustrated in the simplified example of figure 64a. in systems where digital and analog ground planes are connected together somewhere else (at the system? power supply for example), they cannot be connected again near the aduc834 since a ground loop would result. in these cases, tie the aduc834? agnd and dgnd pins all to the analog ground plane, as illustrated in figure 64b. in systems with only one ground plane, ensure that the digital and analog components are physically separated onto separate halves of the board such that digital return currents do not flow near analog circuitry and vice versa. the aduc834 can then be placed between the digital and analog sections, as illustrated in figure 64c. in all of these scenarios, and in more complicated real-life appli- cations, keep in mind the flow of current from the supplies and back to ground. make sure the return paths for all currents are as close as possible to the paths the currents took to reach their destinations. for example, do not power components on the analog side of figure 64b with dv dd since that would force return currents from dv dd to flow through agnd. also, try to avoid digital currents flowing under analog circuitry, which could happen if the user placed a noisy digital chip on the left half of the board in figure 64c. whenever possible, avoid large discontinuities in the ground plane(s) (such as are formed by a long trace on the same layer), since they force return signals to travel a longer path. and of course, make all connections to the ground plane directly, with little or no trace separating the pin from its via to ground.
rev. 0 ?6 aduc834 b. dgnd agnd pl ace analog comp onents here pl ace digital comp onents here c. gnd pl ace analog comp onents here pl ace digital comp onents here a. pl ace analog comp onents here pl ace digital comp onents here dgnd agnd figure 64. system grounding schemes if the user plans to connect fast logic signals (rise/fall time < 5 ns) to any of the aduc834? digital inputs, add a series resistor to each relevant line to keep rise and fall times longer than 5 ns at the aduc834 input pins. a value of 100 w or 200 w is usually sufficient to prevent high speed signals from coupling capaci- tively into the aduc834 and affecting the accuracy of adc conversions. aduc834 system self-identification in some hardware designs, it may be an advantage for the software running on the aduc834 target to identify the host microconverter. for example, code running on the aduc834 may also be used with the aduc824 or the aduc816, and is required to operate differently. the chipid sfr is a read-only register located at sfr address c2h. the upper nibble of this sfr designates the microconverter within the s - d adc family. user software can read this sfr to identify the host microconverter and thus execute slightly different code if required. the chipid sfr reads as follows for the s - d adc family of microconverter products. aduc836 chipid = 3xh aduc834 chipid = 2xh aduc824 chipid = 0xh aduc816 chipid = 1xh clock oscillator as described earlier, the core clock frequency for the aduc834 is generated from an on-chip pll that locks onto a multiple (384 times) of 32.768 khz. the latter is generated from an internal clock oscillator. to use the internal clock oscillator, connect a 32.768 khz parallel resonant crystal between xtal1 and xtal2 pins (32 and 33) as shown in figure 65. as shown in the typical external crystal connection diagram in figure 65, two internal 12 pf capacitors are provided on-chip. these are connected internally, directly to the xtal1 and xtal2 pins, and the total input capacitances at both pins is detailed in the specification section of this data sheet. the value of the total load capacitance required for the external crystal should be the value recommended by the crystal manufacturer for use with that specific crystal. in many cases, because of the on-chip capacitors, additional external load capacitors will not be required. xtal2 xtal1 32.768khz to internal pll aduc834 12pf 12pf 32 33 figure 65. external parallel resonant crystal connections other hardware considerations to facilitate in-circuit programming, plus in-circuit debug and emulation options, users will want to implement some simple connection points in their hardware that will allow easy access to download, debug, and emulation modes.
rev. 0 aduc834 ?7 other hardware considerations in-circuit serial download access nearly all aduc834 designs will want to take advantage of the in-circuit reprogrammability of the chip. this is accomplished by a connection to the aduc834? uart, which requires an external rs-232 chip for level translation if downloading code from a pc. basic configuration of an rs-232 connection is illustrated in figure 66 with a simple adm3202-based circuit. if users would rather not include an rs-232 chip onto the target board, refer to the application note uc006? 4-wire uart-to-pc interface available at www.analog.com/microconverter, for a simple (and zero-cost-per-board) method of gaining in-circuit serial download access to the aduc834. in addition to the basic uart connections, users will also need a way to trigger the chip into download mode. this is accom- plished via a 1 k w pull-down resistor that can be jumpered onto the psen pin, as shown in figure 66. to get the aduc834 into download mode, simply connect this jumper and power-cycle the device (or manually reset the device, if a manual reset button is available) and it will be ready to receive a new program serially. with the jumper removed, the device will power-on in normal mode (and run the program) whenever power is cycled or reset is toggled. note that psen is normally an output (as described in the external memory interface section) and it is sampled as an input only on the falling edge of reset (i.e., at power-up or upon an external manual reset). note also that if any external circuitry unintentionally pulls psen low during power-up or reset events, it could cause the chip to enter download mode and therefore fail to begin user code execution as it should. to prevent this, ensure that no external signals are capable of pulling the psen pin low, except for the external psen jumper itself. embedded serial port debugger from a hardware perspective, entry to serial port debug mode is identical to the serial download entry sequence described above. in fact, both serial download and serial port debug modes can be thought of as essentially one mode of operation used in two different ways. note that the serial port debugger is fully contained on the aduc834 device, (unlike ?om monitor?type debuggers) and therefore no external memory is needed to enable in-system debug sessions. single-pin emulation mode also built into the aduc834 is a dedicated controller for single- pin in-circuit emulation (ice) using standard production aduc834 devices. in this mode, emulation access is gained by connection to a single pin, the ea pin. normally, this pin is hard-wired either high or low to select execution from internal or external program memory space, as described earlier. to enable single-pin emulation mode, however, users will need to pull the ea pin high through a 1 k w resistor as shown in figure 66. the emulator will then connect to the 2-pin header also shown in figure 66. to be compatible with the standard connector that comes with the single-pin emulator available from accutron limited (www.accutron.com), use a 2-pin 0.1-inch pitch friction lock header from molex (www.molex.com) such as their part number 22-27-2021. be sure to observe the polarity of this header. as represented in figure 66, when the friction lock tab is at the right, the ground pin should be the lower of the two pins (when viewed from the top).
rev. 0 ?8 aduc834 typical system configuration a typical aduc834 configuration is shown in figure 66. it summarizes some of the hardware considerations discussed in the previous paragraphs. figure 66 also includes connections for a typical analog measure- ment application of the aduc834, namely an interface to an rtd (resistive temperature device). the arrangement shown is commonly referred to as a 4-wire rtd configuration. here, the on-chip excitation current sources are enabled to excite the sensor. the excitation current flows directly through the rtd generating a voltage across the rtd proportional to its resistance. this differential voltage is routed directly to the positive and negative inputs of the primary adc (ain1, ain2 respec- tively). the same current that excited the rtd also flows through a series resistance r ref generating a ratiometric voltage reference v ref . the ratiometric voltage reference ensures that variations in the excitation current do not affect the measurement system as the input voltage from the rtd and reference voltage across r ref vary ratiometrically with the excitation current. resistor r ref must, however, have a low temperature coefficient to avoid errors in the reference voltage over tem perature. r ref m ust also be large enough to generate at least a 1 v voltage reference. c1+ v+ c1 c2+ c2 v t2out r2in v cc gnd t1out r1in r1out t1in t2in r2out adm3202 dv dd 27 34 33 31 30 29 28 39 38 37 36 35 32 40 47 46 44 43 42 41 52 51 50 49 48 45 dv dd 1k dv dd 1k 2-pin header for emulation access (normally open) download/debug enable jumper (normally open) 32.768khz dv dd 1 2 3 4 5 6 7 8 9 av dd 200 a/400 a excitation current rtd r ref 5.6k av dd agnd p1.2/i exc 1/dac refin refin+ p1.4/ain1 p1.5/ain2 dv dd dgnd psen ea dgnd dv dd xtal2 xtal1 reset rxd txd dv dd dgnd not connected in this example aduc834 p1.3/ain5/dac dv dd rs-232 interface * standard d-type serial comms connector to pc host * external uart transceiver integrated in system or as part of an external dongle as described in uc006. all capacitors in this example are 0.1 f ceramic capacitors figure 66. typical system configuration
rev. 0 aduc834 ?9 quickstart development system the quickstart development system is a full featured, low cost development tool suite supporting the aduc834. the system consists of the following pc-based (windows compatible) hardware and software development tools. hardware: aduc834 evaluation board, and serial port cable code development: 8051 assembler code functionality: adsim, windows microconverter code simulator in-circuit code download: serial downloader in-circuit debugger/emulator: serial port/single pin debugger/emulator with assembly and c source debug miscellaneous other: cd-rom documentation and two additional prototype devices figures 67 shows the typical components of a quickstart devel- opment system while figure 68 shows a typical debug session. a brief description of some of the software tools?components in the quickstart development system is given below. figure 67. components of the quickstart development system download?n circuit downloader the serial downloader is a software program that allows the user to serially download an assembled program (intel hex format file) to the on-chip program flash memory via the serial com1 port on a standard pc. an application note (uc004) detailing this serial download protocol is available from www.analog.com/ microconverter. debugger/emulator?n-circuit debugger/emulator the debugger/emulator is a windows application that allows the user to debug code execution on silicon using the microconverter uart serial port or via a single pin to provide non intrusive debug. the debugger provides access to all on-chip peripherals during a typical debug session, including single-step and mul- tiple break-point code execution control. c source and assembly level debug are both possible with the emulator. adsim?indows simulator the simulator is a windows application that fully simulates the microconverter functionality including adc and dac periph- erals. the simulator provides an easy-to-use, intuitive, interface to the microconverter functionality and integrates many standard debug features, including multiple breakpoints, single stepping, and code execution trace capability. this tool can be used both as a tutorial guide to the part as well as an efficient way to prove code functionality before moving to a hardware platform. figure 68. typical debug session
rev. 0 ?0 aduc834 timing specifications 1, 2, 3 (av dd = 2.7 v to 3.6 v or 4.75 v to 5.25 v, dv dd = 2.7 v to 3.6 v or 4.75 v to 5.25 v; all specifications t min to t max , unless otherwise noted.) 32.768 khz external crystal parameter min typ max unit figure clock input (external clock driven xtal1) t ck xtal1 period 30.52 s69 t ckl xtal1 width low 6.26 s69 t ckh xtal1 width high 6.26 s69 t ckr xtal1 rise time 9 s69 t ckf xtal1 fall time 9 s69 1/t core aduc834 core clock frequency 4 0.098 12.58 mhz t core aduc834 core clock period 5 0.636 s t cyc aduc834 machine cycle time 6 0.95 7.6 122.45 s notes 1 ac inputs during testing are driven at dv dd ?0.5 v for a logic 1, and 0.45 v for a logic 0. timing measurements are made at v ih min for a logic 1, and v il max for a logic 0 as shown in figure 70. 2 for timing purposes, a port pin is no longer floating when a 100 mv change from load voltage occurs. a port pin begins to float when a 100 mv change from the loaded v oh /v ol level occurs as shown in figure 70. 3 c load for port0, ale, psen outputs = 100 pf; c load for all other outputs = 80 pf unless otherwise noted. 4 aduc834 internal pll locks onto a multiple (384 times) the external crystal frequency of 32.768 khz to provide a stable 12.583 mhz internal clock for the system. the core can operate at this frequency or at a binary submultiple called core_clk, selected via the pllcon sfr. 5 this number is measured at the default core_clk operating frequency of 1.57 mhz. 6 aduc834 machine cycle time is nominally defined as 12/core_clk. t ckh t ckl t ck t ckf t ckr figure 69. xtal1 input dv dd ?0.5v 0.45v 0.2dv dd + 0.9v test points 0.2dv dd 0.1v v load ?0.1v v load v load + 0.1v timing reference points v load ?0.1v v load v load + 0.1v figure 70. timing waveform characteristics
rev. 0 aduc834 ?1 12.58 mhz core_clk variable core_clk parameter min max min max unit figure external program memory t lhll ale pulsewidth 119 2t core ?40 ns 71 t avll address valid to ale low 39 t core ?40 ns 71 t llax address hold after ale low 49 t core ?30 ns 71 t lliv ale low to valid instruction in 218 4t core ?100 ns 71 t llpl ale low to psen low 49 t core ?30 ns 71 t plph psen pulsewidth 193 3t core ?45 ns 71 t pliv psen low to valid instruction in 133 3t core ?105 ns 71 t pxix input instruction hold after psen 00 ns71 t pxiz input instruction float after psen 54 t core ?25 ns 71 t aviv address to valid instruction in 292 5t core ?105 ns 71 t plaz psen low to address float 25 25 ns 71 t phax address hold after psen h igh 0 0 ns 71 t lhll t avll pcl (out) instruction (in) pch core_clk ale (o) psen (o) port 0 (i/o) port 2 (o) t llpl t llax t plaz t pxix t pxiz t pliv t lliv t plph t phax t aviv figure 71. external program memory read cycle
rev. 0 ?2 aduc834 12.58 mhz core_clk variable core_clk parameter min max min max unit figure external data memory read cycle t rlrh rd pulsewidth 377 6t core ?100 ns 72 t avll address valid after ale low 39 t core ?40 ns 72 t llax address hold after ale low 44 t core ?35 ns 72 t rldv rd low to valid data in 232 5t core ?165 ns 72 t rhdx data and address hold after rd 00 ns72 t rhdz data float after rd 89 2t core ?70 ns 72 t lldv ale low to valid data in 486 8t core ?150 ns 72 t avdv address to valid data in 550 9t core ?165 ns 72 t llwl ale low to rd low 188 288 3t core ?50 3t core + 50 ns 72 t avwl address valid to rd low 188 4t core ?130 ns 72 t rlaz rd low to address float 0 0 ns 72 t whlh rd high to ale high 39 119 t core ?40 t core + 40 ns 72 t llax data (in) core_clk ale (o) psen (o) port 0 (i/o) port 2 (o) rd (o ) t lldv t llwl t avwl t avll t avdv t rlaz t rldv t rhdx t rhdz t whlh a0?7 (out) a16?23 a8?15 t rlrh figure 72. external data memory read cycle
rev. 0 aduc834 ?3 12.58 mhz core_clk variable core_clk parameter min max min max unit figure external data memory write cycle t wlwh wr pulsewidth 377 6t core ?100 ns 73 t avll address valid after ale low 39 t core ?40 ns 73 t llax address hold after ale low 44 t core ?35 ns 73 t llwl ale low to wr low 188 288 3t core ?50 3t core + 50 ns 73 t avwl address valid to wr low 188 4t core ?130 ns 73 t qvwx data valid to wr transition 29 t core ?50 ns 73 t qvwh data setup before wr 406 7t core ?150 ns 73 t whqx data and address hold after wr 29 t core ?50 ns 73 t whlh wr high to ale high 39 119 t core ?40 t core + 40 ns 73 t llax a0?7 core_clk ale (o) psen (o) port 0 (o) port 2 (o) wr (o ) t whlh t whqx t wlwh t qvwx t qvwh t llwl t avwl t avll a16?23 a8?15 data figure 73. external data memory write cycle
rev. 0 ?4 aduc834 12.58 mhz core_clk variable core_clk parameter min typ max min typ max unit figure uart timing (shift register mode) t xlxl serial port clock cycle time 0.95 12t core s74 t qvxh output data setup to clock 662 10t core ?133 ns 74 t dvxh input data setup to clock 292 2t core + 133 ns 74 t xhdx input data hold after clock 0 0 ns 74 t xhqx output data hold after clock 42 2t core ?117 ns 74 set ri or set ti 01 bit 1 t xlxl ale (o) txd (output clock) rxd (output data) rxd (input data) 67 bit 6 msb msb bit 6 bit 1 lsb t xhqx t qvxh t dvxh t xhdx figure 74. uart timing in shift register mode
rev. 0 aduc834 ?5 parameter min typ max unit figure spi master mode timing (cpha = 1) t sl sclock low pulsewidth * 630 ns 75 t sh sclock high pulsewidth * 630 ns 75 t dav data output valid after sclock edge 50 ns 75 t dsu data input setup time before sclock edge 100 ns 75 t dhd data input hold time after sclock edge 100 ns 75 t df data output fall time 10 25 ns 75 t dr data output rise time 10 25 ns 75 t sr sclock rise time 10 25 ns 75 t sf sclock fall time 10 25 ns 75 * characterized under the following conditions: core clock divider bits cd2, cd1, and cd0 in pllcon sfr set to 0, 1, and 1, respectively, i.e., core clock frequency = 1.57 mhz, and spi bit-rate selection bits spr1 and spr0 in spicon sfr set to 0 and 0, respectively. sclock (cp ol = 0) t dsu sclock (cp ol = 1) mosi miso msb lsb lsb in bits 6? bits 6? t dhd t dr t dav t df t dosu t sh t sl t sr t sf msb in figure 75. spi master mode timing (cpha = 1)
rev. 0 ?6 aduc834 parameter min typ max unit figure spi master mode timing (cpha = 0) t sl sclock low pulsewidth * 630 ns 76 t sh sclock high pulsewidth * 630 ns 76 t dav data output valid after sclock edge 50 ns 76 t dosu data output setup before sclock edge 150 ns 76 t dsu data input setup time before sclock edge 100 ns 76 t dhd data input hold time after sclock edge 100 ns 76 t df data output fall time 10 25 ns 76 t dr data output rise time 10 25 ns 76 t sr sclock rise time 10 25 ns 76 t sf sclock fall time 10 25 ns 76 * characterized under the following conditions: a. core clock divider bits cd2, cd1 and cd0 in pllcon sfr set to 0, 1, and 1 respectively, i.e., core clock frequency = 1.57 mhz, and b. spi bit-rate selection bits spr1 and spr0 in spicon sfr set to 0 and 0 respectively. sclock (cp ol = 0) sclock (cp ol = 1) mosi miso msb in bits 6? bits 6? lsb in lsb msb t dav t df t dr t sr t sf t dhd t dsu t sh t sl figure 76. spi master mode timing (cpha = 0)
rev. 0 aduc834 ?7 parameter min typ max unit figure spi slave mode timing (cpha = 1) t ss ss to sclock edge 0 ns 77 t sl sclock low pulsewidth 330 ns 77 t sh sclock high pulsewidth 330 ns 77 t dav data output valid after sclock edge 50 ns 77 t dsu data input setup time before sclock edge 100 ns 77 t dhd data input hold time after sclock edge 100 ns 77 t df data output fall time 10 25 ns 77 t dr data output rise time 10 25 ns 77 t sr sclock rise time 10 25 ns 75 t sf sclock fall time 10 25 ns 77 t sfs ss high after sclock edge 0 ns 77 sclock (cpol = 0) sclock (cpol = 1) miso mosi ss msb in bits 6 1 lsb in lsb bits 6 1 msb t dhd t dsu t df t dr t sl t sh t dav t sr t sf t sfs t ss figure 77. spi slave mode timing (cpha = 1)
rev. 0 ?8 aduc834 parameter min typ max unit figure spi slave mode timing (cpha = 0) t ss ss to sclock edge 0 ns 78 t sl sclock low pulsewidth 330 ns 78 t sh sclock high pulsewidth 330 ns 78 t dav data output valid after sclock edge 50 ns 78 t dsu data input setup time before sclock edge 100 ns 78 t dhd data input hold time after sclock edge 100 ns 78 t df data output fall time 10 25 ns 78 t dr data output rise time 10 25 ns 78 t sr sclock rise time 10 25 ns 78 t sf sclock fall time 10 25 ns 78 t ssr ss to sclock edge 50 ns 78 t doss data output valid after ss e dge 20 ns 78 t sfs ss high after sclock edge 0 ns 78 miso mosi sclock (cp ol = 1) sclock (cp ol = 0) ss msb bits 6? lsb bits 6? lsb in t dhd t dsu t dr t df t dav t doss t sh t sl t sr t sf t sfs msb in t ss figure 78. spi slave mode timing (cpha = 0)
rev. 0 aduc834 ?9 parameter min max unit figure i 2 c-serial interface timing t l sclock low pulsewidth 4.7 m s79 t h sclock high pulsewidth 4.0 m s79 t shd start condition hold time 0.6 m s79 t dsu data setup time 100 ns 79 t dhd data hold time 0.9 m s79 t rsu setup time for repeated start 0.6 m s79 t psu stop condition setup time 0.6 m s79 t buf bus free time between a stop 1.3 m s79 condition and a start condition t r rise time of both sclock and sdata 300 ns 79 t f fall time of both sclock and sdata 300 ns 79 t sup * pulsewidth of spike suppressed 50 ns 79 * input filtering on both the sclock and sdata inputs surpresses noise spikes less than 50 ns. msb t buf sdata (i/o) sclk (i) stop condition start condition repeated start lsb ack msb 12-78 9 1 s(r) ps t psu t dsu t shd t dhd t sup t dsu t dhd t h t sup t l t rsu t r t r t f t f figure 79. i 2 c compatible interface timing
rev. 0 c02942??1/02(0) printed in u.s.a. ?0 aduc834 outline dimensions 52-lead plastic quad flatpack [mqfp] (s-52) dimensions shown in millimeters seating plane view a 0.23 0.11 2.45 max 1.03 0.88 0.73 top view (pins down) 1 39 40 13 14 27 26 52 pin 1 0.65 bsc 13.45 13.20 sq 12.95 7.80 ref 10.20 10.00 sq 9.80 0.40 0.22 view a rotated 90 ccw 7 0 2.20 2.00 1.80 0.10 min coplanarity compliant to jedec standards mo-022-ac 56-lead lead frame chip scale package [lfcsp] 8 8 mm body (cp-56) dimensions shown in millimeters pin 1 indicator top view 7.75 bsc sq 8.00 bsc sq 1 56 14 15 43 42 28 29 bottom view 6.25 6.10 5.95 0.50 0.40 0.30 0.30 0.23 0.18 0.50 bsc 12 max 0.20 ref 1.00 max 0.65 nom 1.00 0.90 0.80 6.50 ref seating plane 0.10 max 0.60 max 0.60 max pin 1 indicator compliant to jedec standards mo-220-vlld-2 coplanarity 0.08 sq


▲Up To Search▲   

 
Price & Availability of ADUC824B2

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X